oracle使用rownum分页
rownum行号:当我们做select操作时,每查询出的一条记录,就会在该行记录上加上一个行号,行号从一开始,不能跳着走,
排序操作会影响rownum的顺序
rownum不能写上大于一个整数,(rownum>4--错误)
例如,每页10条,查询第二页
select * from( select a.*,rownum rn from ( select * from parm_table_basic_check order by table_name,column_name ) a where rownum<=20) b where b.rn>=11----other
with temp1 as( select * from parm_table_basic_check order by table_name,column_name)select * from( select temp1.*,rownum rn from temp1 where rownum<=20) b where b.rn>=112021-12-11
转载请注明来自海坡下载,本文标题:《oracle分页优化(oracle使用rownum分页)》
京公网安备11000000000001号
京ICP备11000001号
还没有评论,来说两句吧...