HANDLE, SITE, TASK_NO, WORK_CENTER, SHOP_ORDER, ITEM, OP_STEP, RESRCE, SFC, NC_CODE, NC_QTY, LOCATION, STATE,
REMARK, CREATE_USER, CREATED_DATE_TIME, MODIFY_USER, MODIFIED_DATE_TIME, NC_CODE_DESC, REPORT_USER_GROUP
INSERT INTO Z_SELF_REPORT
HANDLE,
SITE,
TASK_NO,
WORK_CENTER,
SHOP_ORDER,
ITEM,
OP_STEP,
RESRCE,
SFC,
NC_CODE,
NC_QTY,
LOCATION,
STATE,
REMARK,
CREATE_USER,
CREATED_DATE_TIME,
MODIFY_USER,
MODIFIED_DATE_TIME,
NC_CODE_DESC,
REPORT_USER_GROUP,
VALUES
#{handle},
#{site},
#{taskNo},
#{workCenter},
#{shopOrder},
#{item},
#{opStep},
#{resrce},
#{sfc},
#{ncCode},
#{ncQty},
#{location},
#{state},
#{remark},
#{createUser},
#{createdDateTime},
#{modifyUser},
#{modifiedDateTime},
#{ncCodeDesc},
#{reportUserGroup},
INSERT INTO Z_SELF_REPORT
VALUES
#{handle},
#{site},
#{taskNo},
#{workCenter},
#{shopOrder},
#{item},
#{opStep},
#{resrce},
#{sfc},
#{ncCode},
#{ncQty},
#{location},
#{state},
#{remark},
#{createUser},
#{createdDateTime},
#{modifyUser},
#{modifiedDateTime},
#{ncCodeDesc},
#{reportUserGroup},
UPDATE Z_SELF_REPORT
SITE=#{et.site},
TASK_NO=#{et.taskNo},
WORK_CENTER=#{et.workCenter},
SHOP_ORDER=#{et.shopOrder},
ITEM=#{et.item},
OP_STEP=#{et.opStep},
RESRCE=#{et.resrce},
SFC=#{et.sfc},
NC_CODE=#{et.ncCode},
NC_QTY=#{et.ncQty},
LOCATION=#{et.location},
STATE=#{et.state},
REMARK=#{et.remark},
CREATE_USER=#{et.createUser},
CREATED_DATE_TIME=#{et.createdDateTime},
MODIFY_USER=#{et.modifyUser},
MODIFIED_DATE_TIME=#{et.modifiedDateTime},
NC_CODE_DESC=#{et.ncCodeDesc},
REPORT_USER_GROUP=#{et.reportUserGroup},
WHERE HANDLE=#{et.handle}
and
${et.MP_OPTLOCK_VERSION_COLUMN}=#{et.MP_OPTLOCK_VERSION_ORIGINAL}
UPDATE Z_SELF_REPORT
SITE=#{et.site},
TASK_NO=#{et.taskNo},
WORK_CENTER=#{et.workCenter},
SHOP_ORDER=#{et.shopOrder},
ITEM=#{et.item},
OP_STEP=#{et.opStep},
RESRCE=#{et.resrce},
SFC=#{et.sfc},
NC_CODE=#{et.ncCode},
NC_QTY=#{et.ncQty},
LOCATION=#{et.location},
STATE=#{et.state},
REMARK=#{et.remark},
CREATE_USER=#{et.createUser},
CREATED_DATE_TIME=#{et.createdDateTime},
MODIFY_USER=#{et.modifyUser},
MODIFIED_DATE_TIME=#{et.modifiedDateTime},
NC_CODE_DESC=#{et.ncCodeDesc},
REPORT_USER_GROUP=#{et.reportUserGroup},
WHERE HANDLE=#{et.handle}
and
${et.MP_OPTLOCK_VERSION_COLUMN}=#{et.MP_OPTLOCK_VERSION_ORIGINAL}
UPDATE Z_SELF_REPORT
SITE=#{et.site},
TASK_NO=#{et.taskNo},
WORK_CENTER=#{et.workCenter},
SHOP_ORDER=#{et.shopOrder},
ITEM=#{et.item},
OP_STEP=#{et.opStep},
RESRCE=#{et.resrce},
SFC=#{et.sfc},
NC_CODE=#{et.ncCode},
NC_QTY=#{et.ncQty},
LOCATION=#{et.location},
STATE=#{et.state},
REMARK=#{et.remark},
CREATE_USER=#{et.createUser},
CREATED_DATE_TIME=#{et.createdDateTime},
MODIFY_USER=#{et.modifyUser},
MODIFIED_DATE_TIME=#{et.modifiedDateTime},
NC_CODE_DESC=#{et.ncCodeDesc},
REPORT_USER_GROUP=#{et.reportUserGroup},
HANDLE=#{ew.entity.handle}
AND SITE=#{ew.entity.site}
AND TASK_NO=#{ew.entity.taskNo}
AND WORK_CENTER=#{ew.entity.workCenter}
AND SHOP_ORDER=#{ew.entity.shopOrder}
AND ITEM=#{ew.entity.item}
AND OP_STEP=#{ew.entity.opStep}
AND RESRCE=#{ew.entity.resrce}
AND SFC=#{ew.entity.sfc}
AND NC_CODE=#{ew.entity.ncCode}
AND NC_QTY=#{ew.entity.ncQty}
AND LOCATION=#{ew.entity.location}
AND STATE=#{ew.entity.state}
AND REMARK=#{ew.entity.remark}
AND CREATE_USER=#{ew.entity.createUser}
AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}
AND MODIFY_USER=#{ew.entity.modifyUser}
AND MODIFIED_DATE_TIME=#{ew.entity.modifiedDateTime}
AND NC_CODE_DESC=#{ew.entity.ncCodeDesc}
AND REPORT_USER_GROUP=#{ew.entity.reportUserGroup}
${ew.sqlSegment}
${ew.sqlSegment}
DELETE FROM Z_SELF_REPORT WHERE HANDLE=#{handle}
DELETE FROM Z_SELF_REPORT
${k} = #{cm[${k}]}
DELETE FROM Z_SELF_REPORT
HANDLE=#{ew.entity.handle}
AND SITE=#{ew.entity.site}
AND TASK_NO=#{ew.entity.taskNo}
AND WORK_CENTER=#{ew.entity.workCenter}
AND SHOP_ORDER=#{ew.entity.shopOrder}
AND ITEM=#{ew.entity.item}
AND OP_STEP=#{ew.entity.opStep}
AND RESRCE=#{ew.entity.resrce}
AND SFC=#{ew.entity.sfc}
AND NC_CODE=#{ew.entity.ncCode}
AND NC_QTY=#{ew.entity.ncQty}
AND LOCATION=#{ew.entity.location}
AND STATE=#{ew.entity.state}
AND REMARK=#{ew.entity.remark}
AND CREATE_USER=#{ew.entity.createUser}
AND CREATED_DATE_TIME=#{ew.entity.createdDateTime}
AND MODIFY_USER=#{ew.entity.modifyUser}
AND MODIFIED_DATE_TIME=#{ew.entity.modifiedDateTime}
AND NC_CODE_DESC=#{ew.entity.ncCodeDesc}
AND REPORT_USER_GROUP=#{ew.entity.reportUserGroup}
${ew.sqlSegment}
${ew.sqlSegment}
DELETE FROM Z_SELF_REPORT WHERE HANDLE IN (
#{item}
)