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

mybatis的oracle分页查询demo

程序员文章站 2022-07-09 20:34:02
...
  <!-- mybatis oracle分页查询 -->
    <select id="getAllMsgByMlh" resultType="java.util.HashMap">
      SELECT *
FROM (SELECT A.*, ROWNUM RU 
          FROM (SELECT  ASJBH,
            PAGENUM
                  FROM jz_dzjz_list
                   WHERE JZMLH = '${jzmlh}'
                 ORDER BY START_PAGE) A
        where ROWNUM <![CDATA[ < ]]> '${end}')
WHERE RU >= '${start}'
    </select>