select top 10 * from YourTable where YourBH not in (select top 10 YourBH from YourTable)

解决方案 »

  1.   

    select top 10 content from [table] where ID not in(select top 10 ID from [table])
      

  2.   

    SQL Server2005(或者Express)是支持行号的。下面这个实在是太恐怖了(假设YourBH是主键):
      select top 20 * from YourTable where 
         YourBH not in (select top 10 YourBH from YourTable order by ...)
         order by ...为了取得一童水竟然要将湖水抽干两次,这大概只有在从来没有面对大于一亩地的“湖”的时候才适用。
      

  3.   

    哦,还写错了。  select * from(select top 20 * from YourTable order by ...) a where 
         YourBH not in (select top 10 YourBH from YourTable order by ...)这通常只是在做作业,特意指出数据库规模限制时有意义。
      

  4.   

    直接用ado.net提供的方法也可以实现~
      

  5.   

    最省事就是做一个(int )型数字code       
    select * from   YourTable   where  (code     between 10  and   20)