<?xml version="1.0" encoding="UTF-8"?>
<queryMap desc="质保书主表">
	<query id="JdgQcmZbsInfoC.insert" desc="新增">
		<![CDATA[
 INSERT INTO QCM_ZBS_INFO_C
  (ZBS_ID,
   ZBS_SEQ,
   JUGDE_APPLY_CODE,
   ORD_LN_DLY_PK,
   ORD_LN_PK,
   CRAFT_SEQ,
   ACT_COUNT,
   ACT_WEIGHT,
   ACT_THEORY_WEIGHT)
VALUES
  ('#ZBS_ID#',
   (SELECT NVL(MAX(A.ZBS_SEQ), 0) + 1
      FROM QCM_ZBS_INFO_C A
     WHERE A.ZBS_ID = '#ZBS_ID#'),
   '#JUGDE_APPLY_CODE#',
   '#ORD_LN_DLY_PK#',
   '#ORD_LN_PK#',
   '#CRAFT_SEQ#',
   '#ACT_COUNT#',
   '#ACT_WEIGHT#',
   '#ACT_THEORY_WEIGHT#')
		]]>
	</query>
	
	<query id="JdgQcmZbsInfoC.delete" desc="删除">
		<![CDATA[
 DELETE FROM QCM_ZBS_INFO_C T
 WHERE T.ZBS_ID = {0}
   AND T.JUGDE_APPLY_CODE = {1}
		]]>
	</query>
	
	<query id="JdgQcmZbsInfoC.deleteByZbsId" desc="删除">
		<![CDATA[
 DELETE FROM QCM_ZBS_INFO_C T
 WHERE T.ZBS_ID = {0}
		]]>
	</query>
</queryMap>