解决oracle数据库in语句参数超过1000的问题

210 阅读1分钟
<select id="getACheckId" resultType="string" parameterType="map">`
     select * where t.contract_id = #{contractId}`
    <if test="ids != null">`
      and
      <foreach collection="ids" index="index" item="idsItem" open="(" separator="or" close=")" >
        t.part_insured_id in
   <foreach collection="idsItem" index="index" item="id" open="(" separator="," close=")" >
   #{id}
</foreach>
</foreach>
</if>
</select>