select * from A where not exists ( select * from B where A.id = B.id )和
select * from A where A.id not in ( select * from B)
select * from A where A.id not in ( select * from B)
本文探讨了两种SQL查询方式:一种是使用NOT EXISTS子句排除匹配项;另一种是利用NOT IN实现相同目的。这两种方法各有优缺点,在不同场景下可能表现出不同的性能特征。
798

被折叠的 条评论
为什么被折叠?