DECLARE @rowsperpage INT
DECLARE @start INT
SET @start = 10002
SET @rowsperpage = 5
SELECT * FROM ( SELECT row_number() OVER (ORDER BY id desc) AS rownum, * FROM my_member ) AS A WHERE A.rownum BETWEEN (@start) AND (@start + @rowsperpage - 1)
Another example:
No comments:
Post a Comment