select top 9 *from 表名 whereid not in (select top 3 * from 表名)
mssql 查询语句中 select top 9 * from 是查询前9条内容。我想查询由第3条开始到第9条内容如何查询求高手给解答
select top 9 *from 表名 whereid not in (select top 3 * from 表名)
select * from table where tableID between 3 and 9用between关键字可以查询指定数的记录。
我想你是想做分页查询,如果是的话,最好是用存储过程或者用自定义函数来实现。这样比较通用一些
尝试使用以下的SQL语句:select top 6 * from (select top 9 * from [table] order by id)order by id desc