SQL Server 2005数据库分页

select *
from Production.Product
where ProductID in (
 select ProductID
 from (
  select ProductID,
   ROW_NUMBER() OVER(ORDER BY ProductID) as nid
  from Production.Product
 ) as tid
 where nid between 21 and 50
)
go
原文地址:https://www.cnblogs.com/bmate/p/1364224.html