传入为 List<Object> 确定为不为空
org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.binding.BindingException: Parameter '__frch_item_0' not found.
<insert id="batchInsert"> insert into
personal_tag(type, tag, create_time, open_account_id)
values
<foreach collection="list" item="item" separator=",">
(#{item.type,jdbcType=INTEGER},
#{item.tag,jdbcType=VARCHAR},
#{item.createTme,jdbcType=TIMESTAMP},
#{item.openAccountId,jdbcType=BIGINT})
</foreach>ON DUPLICATE KEY UPDATE tag=tag
</insert>
代码如上....
确定传入值不为空
代言2016-11-08 14:51:15
ON DUPLICATE KEY UPDATE tag=tag把这一句改为
ON DUPLICATE KEY UPDATE tag=#{item.tag}