oracle的分页语句

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://xxlcube.blog.csdn.net/article/details/8439431

SELECT   *
  FROM   (SELECT   ROWNUM num,
                   e.bid,
                   e.bookname,
                   e.publishtime,
                   e.press,
                   e.money
            FROM   (  SELECT   *
                        FROM   book
                    ORDER BY   bid ASC) e)
 WHERE   num >= 2(起始页号) AND num <= 6(终止页号);


两个参数传入即可,其它的就是修改相应的表名和字段名

展开阅读全文

没有更多推荐了,返回首页