pooney
[MyBatis] foreach를 사용한 merge into update
MyBatis 2020. 7. 26. 19:19

insert into testdb.testsub( sub_idx, parent_idx, sub_keyword ) values (#{item.subIdx}, #{item.mainIdx},#{item.subKeyWord}) ON DUPLICATE KEY UPDATE sub_keyword=VALUES(sub_keyword);