上万条数据如果是一个子查询,或者表
可以用 not exists 或者外连接 判断
根据ID 关联下查查
用not in() 或者 no exists()
比如:select A.id from A where not exists(select 1 from B where A.Id=B.ID)
通过表中唯一标示进行minus操作
如:
select column1 from tab1 --源表
minus
select column1 from tab2 --目标表
上万条数据如果是一个子查询,或者表
可以用 not exists 或者外连接 判断
根据ID 关联下查查
用not in() 或者 no exists()
比如:select A.id from A where not exists(select 1 from B where A.Id=B.ID)
通过表中唯一标示进行minus操作
如:
select column1 from tab1 --源表
minus
select column1 from tab2 --目标表