句式1:
SELECT * FROM (SELECT tb.*,rownum RN FROM
(查询sql语句) tb where rownum<=M) where rn>N句式2:
select * from (
select tb.*, row_number() over(order by 列名 desc) rownumber from (查询sql语句
) tb [where条件]
) where rownumber between N and M;
本文共 300 字,大约阅读时间需要 1 分钟。
句式1:
SELECT * FROM (SELECT tb.*,rownum RN FROM
(查询sql语句) tb where rownum<=M) where rn>N句式2:
select * from (
select tb.*, row_number() over(order by 列名 desc) rownumber from (查询sql语句
) tb [where条件]
) where rownumber between N and M;
转载于:https://www.cnblogs.com/guifang/archive/2012/11/05/2755554.html