求一sql语句? 表t1:字段:a12345表t2:字段:b123怎么得到表t1字段a 4 和5????谢谢了哈 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 select a from t1 where not exists(select 1 from t2 where b = t1.a) select t1.a from t1,t2 where t1.a<>t2.b select t1.* from t1,t2 where a not in (t2.a) select * from 表t1 t where not exists(select 1 from 表t2 where b=t.a) 或者:select a from t1 left join t2 on a=b where b is null select a from t1 where a not in(select b from t2) 求助按缺失字段分组生成记录的sql怎么写? 关于大型 数据库表和设计问题 查询问题请教 sql server的视图是实际存在的物理数据还是只是一段SQL语句?? 外网如何访问单位内部网的sql服务器 怎样让表内字段区分大小写 急急急:一个SQL不知道怎么写,SQL高手进! 大家来帮一下吧!晕死了! 像这样的数据库怎么设计呀? 很急的问题,请大家帮忙! 根据记账月度,得到这个月一共有几周。 向float插入1.0的时候提示 列名或所提供值的数目与表定义不匹配。是什么原因 在线等
select a from t1 where not exists(select 1 from t2 where b = t1.a)
select * from 表t1 t where not exists(select 1 from 表t2 where b=t.a)
或者:
select a from t1 left join t2 on a=b where b is null