sql 2005常用分页

1.select*from ( select row_number()over(orderby tempColumn)tempRowNumber,*from (selecttop 开始位置+10 tempColumn=0,*from Table1)t )tt where tempRowNumber>开始位置

2.select top10*from Table1 where Id>(selectmax(Id) from (selecttop 开始位置 Id from Table1order by Id)tt)

3.select top10*from Table1 where Id notin(selecttop 开始的位置 Id from Table1)

原文地址:https://www.cnblogs.com/caishuowen/p/2611922.html