注意!!!!批量修改需要在jdbc连接后面加上:allowMultiQueries=true 因为默认是不支持批处理的。
<update id="updateList" parameterType="java.util.List">
<foreach collection="list" item="item" index="index" separator=";">
UPDATE t_user
SET update_time = now(),user_name= #{item.userName} ,mobile = #{item.mobile}
WHERE id = #{item.id}
</foreach>
</update>