<?xml version="1.0" encoding="UTF-8"?>
<queryMap desc="新增规格征生成物料 管理">

	<query id="StandardDao.checkDesignGrade" desc="验证钢种">
         <![CDATA[
           SELECT COUNT(1) COUNT
  FROM SLM_ORD_DESIGN_MSC_PL_GZ T
 WHERE T.DESGIN_KEY = ?
   AND T.MSC_PLINE = ?
   AND T.GRADECODE = ?          
         ]]>
	</query>

	<query id="StandardDao.checkRollSpec" desc="验证轧管规格">
         <![CDATA[
           SELECT COUNT(1) COUNT
  FROM SLM_ORD_DESIGN_MSC_GZ_GG T
 WHERE T.DESGIN_KEY = ?
   AND T.MSC_PLINE = ?
   AND T.SPEC_CODE = ?        
         ]]>
	</query>

	<query id="StandardDao.checkBillSpec" desc="验证锻造规格">
         <![CDATA[
           SELECT COUNT(1) COUNT
  FROM SLM_ORD_DESIGN_MSC_BILT T
 WHERE T.DESGIN_KEY = ?
   AND T.MSC_PLINE = ?
   AND T.Spec_Code = ?
   AND T.B_SPEC_CODE = ?      
         ]]>
	</query>

	<query id="StandardDao.checkBillCSpec" desc="验证铸造规格">
         <![CDATA[
           SELECT COUNT(1) COUNT
  FROM SLM_ORD_DESIGN_MSC_BILT_C T
 WHERE T.DESGIN_KEY = ?
   AND T.MSC_PLINE = ?
   AND T.C_SPEC_CODE = ?
   AND T.SPEC_CODE_S = ?     
         ]]>
	</query>

	<query id="StandardDao.checkZCline" desc="验证制程产线">
         <![CDATA[
          SELECT COUNT(1) COUNT
  FROM SLM_ORD_DESIGN_MSC_PL_GX_PRL T
 WHERE T.DESGIN_KEY = ?
   AND T.MSC_PLINE = ?
   AND T.BACKLOG_SEQ = ?
   AND T.PROCESS_CODE = ?
   AND T.PLINE_CODE = ?    
         ]]>
	</query>

	<query id="StandardDao.checkRollLine" desc="验证轧管产线">
         <![CDATA[
          SELECT COUNT(1) COUNT
  FROM SLM_ORD_DESIGN_MSC_GZ_GG_PL T
 WHERE T.DESGIN_KEY = ?
   AND T.MSC_PLINE = ?
   AND T.SPEC_CODE = ?
   AND T.PLINE_CODE = ?  
         ]]>
	</query>

	<query id="StandardDao.checkBillLine" desc="验证锻造产线">
         <![CDATA[
         SELECT COUNT(1) COUNT
  FROM SLM_ORD_DESIGN_MSC_BILT_PL T
 WHERE T.DESGIN_KEY = ?
   AND T.MSC_PLINE = ?
   AND T.B_SPEC_CODE = ?
   AND T.PLINE_CODE = ?
         ]]>
	</query>

	<query id="StandardDao.checkBillCLine" desc="验证铸造产线">
         <![CDATA[
         SELECT COUNT(1) COUNT
  FROM SLM_ORD_DESIGN_MSC_BILT_C_PL T
 WHERE T.DESGIN_KEY = ?
   AND T.MSC_PLINE = ?
   AND T.C_SPEC_CODE = ?
   AND T.PLINE_CODE = ?
         ]]>
	</query>

	<query id="StandardDao.checkProduc" desc="验证制程">
         <![CDATA[
         SELECT COUNT(1) COUNT
  FROM SLM_ORD_DESIGN_MSC_PL T
 WHERE T.DESGIN_KEY = ?
   AND T.MSC_PLINE = ?
         ]]>
	</query>


</queryMap>