PLAN_ID, BATCH_ID, PLAN_NO, CARRIER_ID, PLAN_TRUCK_NUMBER, CAPACITY_TYPE_ID, PLAN_TRUCK_TIME, PLAN_STATUS, MATERIAL_TOTAL_WEIGHT, PLAN_INCOMING_TIME, INSERT_USERNAME, INSERT_TIME, UPDATE_USERNAME, UPDATE_TIME, INSERT_UPDATE_REMARK t.PLAN_ID, t.BATCH_ID, t.PLAN_NO, t.CARRIER_ID, t.PLAN_TRUCK_NUMBER, t.CAPACITY_TYPE_ID, t.PLAN_TRUCK_TIME, t.PLAN_STATUS, t.MATERIAL_TOTAL_WEIGHT, t.PLAN_INCOMING_TIME, t.INSERT_USERNAME, t.INSERT_TIME, t.UPDATE_USERNAME, t.UPDATE_TIME, t.INSERT_UPDATE_REMARK SELECT FROM AMSTRUCK_PURPLAN SELECT FROM AMSTRUCK_PURPLAN t and PLAN_ID = #{planId} and BATCH_ID = #{batchId} and PLAN_NO = #{planNo} and CARRIER_ID = #{carrierId} and PLAN_TRUCK_NUMBER = #{planTruckNumber} and CAPACITY_TYPE_ID = #{capacityTypeId} and TO_CHAR(PLAN_TRUCK_TIME,'yyyy-MM-dd') = #{planTruckTime} and PLAN_STATUS = #{planStatus} and MATERIAL_TOTAL_WEIGHT = #{materialTotalWeight} and TO_CHAR(PLAN_INCOMING_TIME,'yyyy-MM-dd') = #{planIncomingTime} and INSERT_USERNAME = #{insertUsername} and TO_CHAR(INSERT_TIME,'yyyy-MM-dd') = #{insertTime} and UPDATE_USERNAME = #{updateUsername} and TO_CHAR(UPDATE_TIME,'yyyy-MM-dd') = #{updateTime} and INSERT_UPDATE_REMARK = #{insertUpdateRemark} and PLAN_ID = #{planId} and BATCH_ID = #{batchId} and PLAN_NO LIKE '%${planNo}%' and CARRIER_ID = #{carrierId} and PLAN_TRUCK_NUMBER = #{planTruckNumber} and CAPACITY_TYPE_ID = #{capacityTypeId} and TO_CHAR(PLAN_TRUCK_TIME,'yyyy-MM-dd') = #{planTruckTime} and PLAN_STATUS = #{planStatus} and MATERIAL_TOTAL_WEIGHT = #{materialTotalWeight} and TO_CHAR(PLAN_INCOMING_TIME,'yyyy-MM-dd') = #{planIncomingTime} and INSERT_USERNAME LIKE '%${insertUsername}%' and TO_CHAR(INSERT_TIME,'yyyy-MM-dd') = #{insertTime} and UPDATE_USERNAME LIKE '%${updateUsername}%' and TO_CHAR(UPDATE_TIME,'yyyy-MM-dd') = #{updateTime} and INSERT_UPDATE_REMARK LIKE '%${insertUpdateRemark}%' delete from AMSTRUCK_PURPLAN where PLAN_ID = #{planId,jdbcType=DECIMAL} delete from AMSTRUCK_PURPLAN where 1!=1 or BATCH_ID = #{batchId} or PLAN_NO = #{planNo} or CARRIER_ID = #{carrierId} or PLAN_TRUCK_NUMBER = #{planTruckNumber} or CAPACITY_TYPE_ID = #{capacityTypeId} or TO_CHAR(PLAN_TRUCK_TIME,'yyyy-MM-dd') = '#{planTruckTime}' or PLAN_STATUS = #{planStatus} or MATERIAL_TOTAL_WEIGHT = #{materialTotalWeight} or TO_CHAR(PLAN_INCOMING_TIME,'yyyy-MM-dd') = '#{planIncomingTime}' or INSERT_USERNAME = #{insertUsername} or TO_CHAR(INSERT_TIME,'yyyy-MM-dd') = '#{insertTime}' or UPDATE_USERNAME = #{updateUsername} or TO_CHAR(UPDATE_TIME,'yyyy-MM-dd') = '#{updateTime}' or INSERT_UPDATE_REMARK = #{insertUpdateRemark} insert into AMSTRUCK_PURPLAN (PLAN_ID, BATCH_ID, PLAN_NO, CARRIER_ID, PLAN_TRUCK_NUMBER, CAPACITY_TYPE_ID, PLAN_TRUCK_TIME, PLAN_STATUS, MATERIAL_TOTAL_WEIGHT, PLAN_INCOMING_TIME, INSERT_USERNAME, INSERT_TIME, UPDATE_USERNAME, UPDATE_TIME, INSERT_UPDATE_REMARK ) values (#{planId,jdbcType=DECIMAL}, #{batchId,jdbcType=DECIMAL}, #{planNo,jdbcType=VARCHAR}, #{carrierId,jdbcType=DECIMAL}, #{planTruckNumber,jdbcType=DECIMAL}, #{capacityTypeId,jdbcType=DECIMAL}, #{planTruckTime,jdbcType=TIMESTAMP}, #{planStatus,jdbcType=DECIMAL}, #{materialTotalWeight,jdbcType=DECIMAL}, #{planIncomingTime,jdbcType=TIMESTAMP}, #{insertUsername,jdbcType=VARCHAR}, #{insertTime,jdbcType=TIMESTAMP}, #{updateUsername,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}, #{insertUpdateRemark,jdbcType=VARCHAR} ) insert into AMSTRUCK_PURPLAN PLAN_ID, BATCH_ID, PLAN_NO, CARRIER_ID, PLAN_TRUCK_NUMBER, CAPACITY_TYPE_ID, PLAN_TRUCK_TIME, PLAN_STATUS, MATERIAL_TOTAL_WEIGHT, PLAN_INCOMING_TIME, INSERT_USERNAME, INSERT_TIME, UPDATE_USERNAME, UPDATE_TIME, INSERT_UPDATE_REMARK, #{planId,jdbcType=DECIMAL}, #{batchId,jdbcType=DECIMAL}, #{planNo,jdbcType=VARCHAR}, #{carrierId,jdbcType=DECIMAL}, #{planTruckNumber,jdbcType=DECIMAL}, #{capacityTypeId,jdbcType=DECIMAL}, #{planTruckTime,jdbcType=TIMESTAMP}, #{planStatus,jdbcType=DECIMAL}, #{materialTotalWeight,jdbcType=DECIMAL}, #{planIncomingTime,jdbcType=TIMESTAMP}, #{insertUsername,jdbcType=VARCHAR}, #{insertTime,jdbcType=TIMESTAMP}, #{updateUsername,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}, #{insertUpdateRemark,jdbcType=VARCHAR}, update AMSTRUCK_PURPLAN set BATCH_ID = #{batchId,jdbcType=DECIMAL}, PLAN_NO = #{planNo,jdbcType=VARCHAR}, CARRIER_ID = #{carrierId,jdbcType=DECIMAL}, PLAN_TRUCK_NUMBER = #{planTruckNumber,jdbcType=DECIMAL}, CAPACITY_TYPE_ID = #{capacityTypeId,jdbcType=DECIMAL}, PLAN_TRUCK_TIME = #{planTruckTime,jdbcType=TIMESTAMP}, PLAN_STATUS = #{planStatus,jdbcType=DECIMAL}, MATERIAL_TOTAL_WEIGHT = #{materialTotalWeight,jdbcType=DECIMAL}, PLAN_INCOMING_TIME = #{planIncomingTime,jdbcType=TIMESTAMP}, INSERT_USERNAME = #{insertUsername,jdbcType=VARCHAR}, INSERT_TIME = #{insertTime,jdbcType=TIMESTAMP}, UPDATE_USERNAME = #{updateUsername,jdbcType=VARCHAR}, UPDATE_TIME = #{updateTime,jdbcType=TIMESTAMP}, INSERT_UPDATE_REMARK = #{insertUpdateRemark,jdbcType=VARCHAR} where PLAN_ID = #{planId,jdbcType=DECIMAL} update AMSTRUCK_PURPLAN BATCH_ID = #{batchId,jdbcType=DECIMAL}, PLAN_NO = #{planNo,jdbcType=VARCHAR}, CARRIER_ID = #{carrierId,jdbcType=DECIMAL}, PLAN_TRUCK_NUMBER = #{planTruckNumber,jdbcType=DECIMAL}, CAPACITY_TYPE_ID = #{capacityTypeId,jdbcType=DECIMAL}, PLAN_TRUCK_TIME = #{planTruckTime,jdbcType=TIMESTAMP}, PLAN_STATUS = #{planStatus,jdbcType=DECIMAL}, MATERIAL_TOTAL_WEIGHT = #{materialTotalWeight,jdbcType=DECIMAL}, PLAN_INCOMING_TIME = #{planIncomingTime,jdbcType=TIMESTAMP}, INSERT_USERNAME = #{insertUsername,jdbcType=VARCHAR}, INSERT_TIME = #{insertTime,jdbcType=TIMESTAMP}, UPDATE_USERNAME = #{updateUsername,jdbcType=VARCHAR}, UPDATE_TIME = #{updateTime,jdbcType=TIMESTAMP}, INSERT_UPDATE_REMARK = #{insertUpdateRemark,jdbcType=VARCHAR}, where PLAN_ID = #{planId,jdbcType=DECIMAL} insert into AMSTRUCK_PURPLAN (PLAN_ID, BATCH_ID, PLAN_NO, CARRIER_ID, PLAN_TRUCK_NUMBER, CAPACITY_TYPE_ID, PLAN_TRUCK_TIME, PLAN_STATUS, MATERIAL_TOTAL_WEIGHT, PLAN_INCOMING_TIME, INSERT_USERNAME, INSERT_TIME, UPDATE_USERNAME, UPDATE_TIME, INSERT_UPDATE_REMARK) ( select #{item.planId,jdbcType=DECIMAL}, #{item.batchId,jdbcType=DECIMAL}, #{item.planNo,jdbcType=VARCHAR}, #{item.carrierId,jdbcType=DECIMAL}, #{item.planTruckNumber,jdbcType=DECIMAL}, #{item.capacityTypeId,jdbcType=DECIMAL}, #{item.planTruckTime,jdbcType=TIMESTAMP}, #{item.planStatus,jdbcType=DECIMAL}, #{item.materialTotalWeight,jdbcType=DECIMAL}, #{item.planIncomingTime,jdbcType=TIMESTAMP}, #{item.insertUsername,jdbcType=VARCHAR}, #{item.insertTime,jdbcType=TIMESTAMP}, #{item.updateUsername,jdbcType=VARCHAR}, #{item.updateTime,jdbcType=TIMESTAMP}, #{item.insertUpdateRemark,jdbcType=VARCHAR} from dual ) update AMSTRUCK_PURPLAN set PLAN_ID= when #{item.planId,jdbcType=DECIMAL} then #{item.planId,jdbcType=DECIMAL} ,BATCH_ID= when #{item.planId,jdbcType=DECIMAL} then #{item.batchId,jdbcType=DECIMAL} ,PLAN_NO= when #{item.planId,jdbcType=DECIMAL} then #{item.planNo,jdbcType=VARCHAR} ,CARRIER_ID= when #{item.planId,jdbcType=DECIMAL} then #{item.carrierId,jdbcType=DECIMAL} ,PLAN_TRUCK_NUMBER= when #{item.planId,jdbcType=DECIMAL} then #{item.planTruckNumber,jdbcType=DECIMAL} ,CAPACITY_TYPE_ID= when #{item.planId,jdbcType=DECIMAL} then #{item.capacityTypeId,jdbcType=DECIMAL} ,PLAN_TRUCK_TIME= when #{item.planId,jdbcType=DECIMAL} then #{item.planTruckTime,jdbcType=TIMESTAMP} ,PLAN_STATUS= when #{item.planId,jdbcType=DECIMAL} then #{item.planStatus,jdbcType=DECIMAL} ,MATERIAL_TOTAL_WEIGHT= when #{item.planId,jdbcType=DECIMAL} then #{item.materialTotalWeight,jdbcType=DECIMAL} ,PLAN_INCOMING_TIME= when #{item.planId,jdbcType=DECIMAL} then #{item.planIncomingTime,jdbcType=TIMESTAMP} ,INSERT_USERNAME= when #{item.planId,jdbcType=DECIMAL} then #{item.insertUsername,jdbcType=VARCHAR} ,INSERT_TIME= when #{item.planId,jdbcType=DECIMAL} then #{item.insertTime,jdbcType=TIMESTAMP} ,UPDATE_USERNAME= when #{item.planId,jdbcType=DECIMAL} then #{item.updateUsername,jdbcType=VARCHAR} ,UPDATE_TIME= when #{item.planId,jdbcType=DECIMAL} then #{item.updateTime,jdbcType=TIMESTAMP} ,INSERT_UPDATE_REMARK= when #{item.planId,jdbcType=DECIMAL} then #{item.insertUpdateRemark,jdbcType=VARCHAR} where PLAN_ID in #{item.planId,jdbcType=DECIMAL} delete from AMSTRUCK_PURPLAN where PLAN_ID in #{id} order by "${orderField}" ${orderType}