select * from table1 A where not exists (select * from table2 where col1 = A.col1 and col2 = A.col2)
解决方案 »
- SQL2005导出数据到Excel遇到的问题
- 给个意见吧
- 各位大侠,问个批处理文件里调用参数的问题(bcp命令)
- 请教字符串匹配显示结果问题?
- 求一条SQL语句! 各位路过的帮帮忙,不甚感谢!
- 如何在存储过程中将一个查询到的多条记录插入到另外一个表中?
- 请问如何将一个表中所有内容导出为sql脚本
- 连接SQL Server 2008(64bit)报错([DBNMPNTW]Connection is busy.)
- 如何把一数据库中某字段的数据无重复地提取,寻求简易做法,超急!
- 如何求SQL时间差之和,就是多条记录,开始时间和结束时间的和的累积
- numeric的问题
- 修改了一笔数据后触发了触发器,而后弹出下面的错误信息,不知何故,如何解决?
(select * from table2 where col1 = table1.col1 and col2 = table1.col2)
select a.*
from table1 a left join table1 b on a.col1=b.col1 and a.col2=b.col2
where b.a is null