Maybatis에서 foreach를 사용해서 다중 update를 해보려고 합니다.
DBMS는 오라클 입니다.
<update id="updateList" parameterType="java.util.Map">
<foreach collection="list" item="item" index="index" separator=";" open="DECLARE BEGIN" close="; END;">
UPDATE TEMP
CONTENT
<where>
NO = #{item.no}
</where>
</foreach>
</update>
insert와 다르게 separator=";" open="DEVLARE BEGIN" close=";END;"를 작성해주면 됩니다.