SQL Server 2005新增功能--Row_NUMBER() 分页查询

<!--很有用的东西,在配合flexigrid。用起来真舒服。-->

SELECT
* FROM ( SELECT ROW_NUMBER() OVER ( ORDER BY DATE) ROWNUM, * FROM BAS_CALENDAR ) CAL WHERE ROWNUM BETWEEN ( 50 * 1 ) + 1 AND 50 * 2 ORDER BY DATE ASC

 

posted @ 2012-08-06 17:25  ω♪zone咕咯  阅读(157)  评论(0编辑  收藏  举报