您的位置:首页 > 博客中心 > 数据库 >

Oracle中用一个表的数据更新另一个表的数据

时间:2022-03-13 23:13

update tbl1 a
   set (a.col1, a.col2) = (select b.col1, b.col2
                              from tbl2 b
                              where a.key = b.key)
   where a.key in(select key from tbl2)

本类排行

今日推荐

热门手游