sql server 分页

时间:2021-01-17 07:25:38
【文件属性】:

文件名称:sql server 分页

文件大小:544B

文件格式:TXT

更新时间:2021-01-17 07:25:38

sql server 分页

sql server分页代码 --分页【top】:不支持复合主键 SELECT TOP 10 * from Lend where id not in (SELECT TOP ((2-1)*10) id from lend ORDER BY id) ORDER BY id ; SELECT TOP 10 * from Lend where id not in (SELECT TOP 10 id from lend ORDER BY id) ; SELECT * FROM Nect; --分页【max】:不支持非唯一列排序 select top 10 * from table1 where id>(select max(id) from (select top 开始位置 id from table1 order by id)tt) SELECT TOP 10 * from Lend WHERE id> (SELECT MAX(id) FROM (SELECT top 10 id FROM Lend ORDER BY id) M)


网友评论