SQL2005 分页查询
WITH O AS( SELECT ROW_NUMBER() OVER(ORDER BY ID DESC) AS ROW, * FROM USERS WHERE SHOP_ID IS NOT NULL ) SELECT * FROM O WHERE ROW BETWEEN @BEGIN AND @END