replace INTO erpstock ( orderId,code,batchNo,manufacturingDate,expirationDate,count,remark,name ) values ( #{orderId}, #{code}, #{batchNo}, #{manufacturingDate}, #{count}, #{remark}, #{name} ) replace INTO erpstock ( orderId,code,batchNo,manufacturingDate,expirationDate,count,remark,name ) values ( #{item.orderId}, #{item.code}, #{item.batchNo}, #{item.manufacturingDate}, #{item.expirationDate}, #{item.count}, #{item.remark}, #{item.name} ) DELETE FROM erpstock WHERE id = #{id} UPDATE erpstock orderId=#{orderId}, code=#{code}, batchNo=#{batchNo}, manufacturingDate=#{manufacturingDate}, expirationDate=#{expirationDate}, count=#{count}, remark=#{remark}, name=#{name}, WHERE id = #{id}