in 里面超过1000条解决办法 「爱情、让人受尽委屈。」 2021-12-18 18:47 168阅读 0赞 <if test="orgList !=null and orgList.size>0"> and dept\_code in <!--处理in的集合超过1000条时oracle不支持的情况--> <trim suffixOverrides=" or dept\_code in()"> <!--表示删除最后一个条件--> <foreach collection="orgList" item="org" index="index" open="(" close =")"> <if test="index !=0"> <choose> <when test="index % 1000==999">) or dept\_code in ( </when> <otherwise>,</otherwise> </choose> </if> \#\{org\} </foreach> </trim> </if>
还没有评论,来说两句吧...