阅读392 返回首页    go 京东网上商城


要求从表A查数据插入到表B中,并且要求如果表A中已存在的数据,就不要重复插入

  insert into A select * from B where not exists (select 1 from A where A.ID=B.ID)

  insert when (not exists (select 1 from 表名 where 检验重复的条件)) then into 表名 values(相应的值)select 1 from dual

最后更新:2017-04-03 12:54:15

  上一篇:go 排序算法测试程序入口
  下一篇:go 虚机能ping通主机但主机ping不通虚机