日期:2014-05-18 浏览次数:20684 次
if exists(select 1 from tb where d='a' or d='b') print '存在' else print '不存在'
------解决方案--------------------
if exists(select 1 from tb where d in('a', 'b') having count(distinct d)=2)
print '同时存在a/b'
else
print '不存在'
------解决方案--------------------