<?xml version="1.0" encoding="UTF-8"?>
<queryMap desc="炼钢计划辅助类">

	<query id="SteelHelper.initPline" desc="初始化产线">
             <![CDATA[
                  SELECT T.PLINE_CODE,T.PLINE_NAME FROM COM_BASE_PLINE T WHERE T.PROCESS_CODE=?  AND T.VALIDFLAG='1' AND instr(T.PLINE_NAME,'外购')=0 ORDER BY T.PLINE_CODE 
                  ]]>
	</query>

	<query id="SteelHelper.initGrade" desc="初始化钢种">
             <![CDATA[
                SELECT T.GRADECODE,T.GRADENAME FROM COM_BASE_GRADE T WHERE T.VALIDFLAG='1' ORDER BY T.GRADENAME
                  ]]>
	</query>
	
		<query id="SteelHelper.initProcess" desc="初始化工序">
             <![CDATA[
                 SELECT T.PROCESS_CODE, T.PROCESS_DESC FROM COM_BASE_PROCESS T  WHERE  T.PROCESS_CODE=? AND T.VALIDFLAG = '1'
                  ]]>
	</query>

	<query id="SteelHelper.getCastGroup" desc="查询连浇群组">
             <![CDATA[
            SELECT WATER_GROUP_CODE,
       WATER_GROUP,
       GRADECODE,
       GRADENAME,
       GRADE_INDEX,
       CREATE_TIME,
       CREATE_NAME
  FROM COM_BASE_WATER_GROUP T
 WHERE T.WATER_GROUP_CODE = ?
   AND T.GRADE_INDEX > (SELECT T1.GRADE_INDEX
                          FROM COM_BASE_WATER_GROUP T1
                         WHERE T1.WATER_GROUP_CODE = ?
                           AND T1.GRADECODE = ?)
 ORDER BY TO_NUMBER(T.GRADE_INDEX)
                  ]]>
	</query>



</queryMap>