5,889
社区成员
发帖
与我相关
我的任务
分享
update score set score.YW=89 from student where score.XH=student.XH and student.XM='张三凤'
欢迎来看我的博客:《SQL从入门到出门》。
db2 => connect to hrdb user db2inst1 using xxxxxx
Database Connection Information
Database server = DB2/LINUXX8664 11.1.2.2
SQL authorization ID = DB2INST1
Local database alias = HRDB
db2 =>
update score set score.YW=89 from student where score.XH=student.XH and student.XM='张三凤'
db2 => DB20000I The SQL command completed successfully.
db2 "update score set score.YW=89 from student where score.XH=student.XH and student.XM='张三凤'"
你比较一下,这就是 update 使用 inner join 的写法。