mybatis中sql子查询无返回结果
<selectid="fyQuery"parameterType="java.lang.String"resultMap="ListDemo">selectdid,dna...
<select id="fyQuery" parameterType="java.lang.String" resultMap="ListDemo">
select did,dname from (select t.did,t.dname,rownum rn from demo t where rownum <= ${end})x where rn >= ${start}
</select>
<resultMap type="demo" id="ListDemo">
<id column="did" property="did"/>
<result column="dname" property="dname"/>
</resultMap>
查询没报错就是没有返回结果,sql在数据库中也能跑 展开
select did,dname from (select t.did,t.dname,rownum rn from demo t where rownum <= ${end})x where rn >= ${start}
</select>
<resultMap type="demo" id="ListDemo">
<id column="did" property="did"/>
<result column="dname" property="dname"/>
</resultMap>
查询没报错就是没有返回结果,sql在数据库中也能跑 展开
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询