一、Mapper层
void updateTable_patch(@Param("list") List<Map<String,String>> list);
二、xml
<update id="updateTable_patch">
<foreach collection="list" item="item" index="index" separator=";" open="begin" close=";end;">
update STUDENT t set t.student_name='${item.student_name}'
<where>
<if test="item.age!=null and item.age!=''">
and t.age='${item.age}'
</if>
<if test="item.address!= null and item.address!=''">
and t.address='${item.address}'
</if>
<if test="item.time!=null and item.time!=''">
and t.time=to_date('${item.time}','yyyy-mm-dd hh24:mi:ss')
</if>
</where>
</foreach>
</update>