取得第20-30条数据:
select top 10 * from userinfo where id not in (select top 20 id from userinfo)
select top 10 * from userinfo where id not in (select top 20 id from userinfo)
本文介绍了一种使用SQL进行分页查询的方法,通过not in子句实现从第20条记录开始获取接下来的10条记录。这种方法适用于需要跳过前几页数据直接访问特定位置记录的场景。

被折叠的 条评论
为什么被折叠?