<?xml version="1.0" encoding="UTF-8"?>
<queryMap desc="删除产线">

	<query id="DeleteLineDao.getQualityDesignLine" desc="查询质量设计产线结果">  
             <![CDATA[ 
SELECT T1.DESGIN_KEY,
       T1.MSC_PLINE,
       T1.BACKLOG_SEQ,
       T1.PROCESS_CODE,
       T1.PLINE_CODE,
       T1.PLINE_NAME,
       T1.WELL_CODE,
       T1.WELL_NAME,
       T1.WARN_FL,
       T1.WARN_DESC,
       T1.VALIDFLAG,
       T1.IDENT_FLAG
  FROM SLM_ORD_DESIGN_MSC_PL_GX_PRL T1, SLM_ORD_DESIGN_MSC T2
 WHERE T1.DESGIN_KEY = T2.DESGIN_KEY
 AND T2.ORD_LN_PK = ?
   AND T2.VALIDFLAG = '1'
          ]]>
	</query>

	<query id="DeleteLineDao.getQualityDesignLine2" desc="查询质量设计产线结果2">  
             <![CDATA[ 
SELECT T1.DESGIN_KEY,
       T1.MSC_PLINE,
       T1.BACKLOG_SEQ,
       T1.PROCESS_CODE,
       T1.PLINE_CODE,
       T1.PLINE_NAME,
       T1.WELL_CODE,
       T1.WELL_NAME,
       T1.WARN_FL,
       T1.WARN_DESC,
       T1.VALIDFLAG,
       T1.IDENT_FLAG
  FROM SLM_ORD_DESIGN_MSC_PL_GX_PRL T1, SLM_ORD_DESIGN_MSC T2
 WHERE T1.DESGIN_KEY = T2.DESGIN_KEY
   AND T2.ORD_LN_PK = {0}
   AND T2.VALIDFLAG = '1'
   AND T1.VALIDFLAG = '0'
          ]]>
	</query>

	<query id="DeleteLineDao.deleteCraftLine" desc="删除工艺评审产线">  
             <![CDATA[ 
                DELETE FROM CRAFT_ORD_DESIGN_MSC_PL_GX_PRL T
 WHERE T.DESGIN_KEY = ?
   AND T.MSC_PLINE = ?
   AND T.PROCESS_CODE = ?
   AND T.PLINE_CODE = ?
   AND T.IDENT_FLAG='0'
                     ]]>
	</query>

</queryMap>