Oracle分页SQL

查询所有及rownum时需要在rownum之前的*必须使用表的名称country.*

select * from (select country.*,rownum rn from country where rownum < 9) a where rn > 2

分页查询示例

select a.*,rownum as rn from (select * from country where rownum < 9) a where rn > 2 
-- ORA-00904: "RN": invalid identifier (rn不是a表的列) select * from (select a.*,rownum rn from (select * from country where rownum < 9) a ) where rn > 2

 

 

上一篇:P10 凸函数的扩展


下一篇:ReactNative 详解(四) 源码之RN启动过程