欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

数据库分页

程序员文章站 2022-04-22 10:25:15
...

DB2分页
SELECT * FROM (
 select rownumber() over(order by tkjl.txsj DESC) as rownum,tkjl.* FROM XXXXX tkjl
)where rownum < 100

 

SELECT * FROM (
 select rownumber() over(order by tkjl.txsj DESC) as rownum,tkjl.* FROM XXXX tkjl
)where rownum between 1 and 20


MYSQL分页
select * from Userinfo limit 1,20

 

Oracle 分页
select * from (
 select rownum,k.* from XXXXX k where kadm like '32%'
) where rownum between 1 and 20

 

--每次取得10条数据
select * from (
 select rownum,k.* from XXXXX   k where kadm like '32%'
) where rownum <11

相关标签: 数据库分页