<resultMap id="testVo" type="com.test.vo.TestVo">
<collection property="testInfos" javaType="java.util.List"
select="com.test.mapper.TestInfoMapper.innerSelectByMap" column="{id=id,title=title}" ofType="java.util.Map"/>
<!-- 外部接口 -->
<select id="queryList" resultMap="testVo">
select id, title from test where uid=#{uid}
</select>
<!-- innerXXX: 内部操作方法,不对外提供接口 -->
<select id="innerSelectByMap" resultType="com.test.entity.TestInfo" parameterType="java.util.Map">
select * from test_info where 1=1
<foreach collection="_parameter" separator="" index="key" item="value" open="" close="">
and `${key}` = #{value}
</foreach>
</select>
当调用queryList时,如果获得的结果中title为null,则传入到innerSelectByMap的参数只有一个,如果id、title不为null,则可以正常的传入两个参数。
这个bug如何解决????