如何选择内部选择语句未选择的记录?

时间:2010-11-14 13:41:36

标签: sql sql-server

select pid from table where pid is not (select top 10 pid from table1)

上述语法的正确语法是什么?

2 个答案:

答案 0 :(得分:2)

select pid from table where pid not in (select top 10 pid from table1)

答案 1 :(得分:2)

not in,而不是is not