INSERT INTO warehouse(action,mainAction,code,corpOrderId,actor,actDate,wrongCode,upperCorpOrderId,fromCorpId,fromCorp,type) values( #{action}, #{mainAction}, #{code}, #{corpOrderId}, #{actor}, #{actDate}, #{wrongCode}, #{upperCorpOrderId}, #{fromCorpId}, #{fromCorp},#{orderId},#{type}) INSERT INTO warehouse (action, mainAction, code, corpOrderId, actor, actDate, wrongCode, upperCorpOrderId, fromCorpId,fromCorp,orderId,batchNo,produceDate,expireDate,serialNo,udi,count,type) VALUES ( #{item.action}, #{item.mainAction}, #{item.code}, #{item.corpOrderId}, #{item.actor}, #{item.actDate}, #{item.wrongCode}, #{item.upperCorpOrderId}, #{item.fromCorpId}, #{ item.fromCorp },#{item.orderId},#{item.batchNo} ,#{item.produceDate} ,#{item.expireDate} ,#{item.serialNo} ,#{item.udi} ,#{item.count} ,#{item.type}) UPDATE warehouse SET orderId = #{newOrderId} where orderId = #{oldOrderId} UPDATE warehouse SET fromCorpID = #{fromCorpID}, fromCorp = #{fromCorp} WHERE orderId = #{orderId}