a表里面有2个字段 aa bb
1
2b表里面有一个字段
aa
1
2
3
4select aa from b where not in(select aa from a)这样没有错,但是select aa from b where not in(select bb from a)这样就没有返回值了,,大家帮忙看看啊,
1
2b表里面有一个字段
aa
1
2
3
4select aa from b where not in(select aa from a)这样没有错,但是select aa from b where not in(select bb from a)这样就没有返回值了,,大家帮忙看看啊,
你可以这样:
select aa from b where not in(select isnull(bb,'') as col1 from a)