<?xml version="1.0" encoding="UTF-8"?>
<queryMap desc="基础信息">
	<query id="JdgQcmLgChemResult.getByJudgeStoveNo" desc="通过判定炉号查询">
		<![CDATA[
SELECT B.JUDGE_STOVE_NO, B.SAMPLE_NO, B.PROCESS_CDOE PROCESS_CODE, A.QUALIFIED NK_QUALIFIED, A.*
  FROM QCM_LG_CHEM_RESULT A, QCM_LG_CHEMJUDGE B
 WHERE A.CHEM_JUDGE_ID = B.CHEM_JUDGE_ID
   AND A.JUDGE_SEQ = B.JUDGE_SEQ
   AND B.VALIDFLAG = '1'
   AND B.JUDGE_STOVE_NO = {0}
   AND B.PROCESS_CDOE = {1}
		]]>
	</query>
	
	<query id="JdgQcmLgChemResult.insert" desc="新增">
		<![CDATA[
 INSERT INTO QCM_LG_CHEM_RESULT(
        CHEM_JUDGE_ID,
        JUDGE_SEQ,
        CHEM_SEQ,
        CHEM_NAME,
        CHEM_VALUE,
        NK_MIN,
        NK_MAX,
        QUALIFIED,
        UNQUALIFIED_TYPE)
 VALUES( 
        '#CHEM_JUDGE_ID#',
        '#JUDGE_SEQ#',
        '#CHEM_SEQ#',
        '#CHEM_NAME#',
        '#CHEM_VALUE#',
        '#NK_MIN#',
        '#NK_MAX#',
        '#QUALIFIED#',
        '#UNQUALIFIED_TYPE#')
		]]>
	</query>

	<query id="JdgQcmLgChemResult.getJfFail" desc="获取交付失败记录">
		<![CDATA[
 SELECT A.*
  FROM QCM_LG_CHEMJUDGE T, QCM_LG_CHEM_RESULT A
 WHERE T.JUDGE_STOVE_NO = {0}
   AND T.VALIDFLAG = '1'
   AND A.CHEM_JUDGE_ID = T.CHEM_JUDGE_ID
   AND A.JUDGE_SEQ = T.JUDGE_SEQ
   AND A.JF_QUALIFIED IN ('0', '2')
		]]>
	</query>
</queryMap>