标签:
1.MySql分页
2.Slq Server 分页
sql2000
1 select top 10 * 2 from table1 3 where id not in( 4 select top 开始的位置 id 5 from table1)
sql2005-sql2008
1 SELECT * FROM (SELECT *, ROW_NUMBER() OVER(Order by a.CreateTime DESC ) AS RowNumber FROM table_name AS a ) AS b WHERE RowNumber BETWEEN @PageIndex AND @PageSiez;
sql2012
1 SELECT LastName, FirstName, EmailAddress 2 FROM Employee 3 ORDER BY LastName, FirstName, EmailAddress 4 OFFSET 14000 ROWS 5 FETCH NEXT 50 ROWS ONLY;
标签:
原文地址:http://www.cnblogs.com/liuxiaoji/p/4723718.html