INSERT INTO b SELECT * FROM a WHERE NOT EXISTS (SELECT b.* FROM b WHERE b.id = a.id)
oracle中查询出A表的结果,并将A表中的数据插入到B表中,对于A表中已经存在的B表数据不在插入
最新推荐文章于 2023-04-06 14:28:10 发布
INSERT INTO b SELECT * FROM a WHERE NOT EXISTS (SELECT b.* FROM b WHERE b.id = a.id)