<?xml version="1.0" encoding="UTF-8"?>
<queryMap desc="接箍公共信息">

	<query id="FrmDealOut.queryOutPerfo" desc="查询交易表倒库实绩">		
        <![CDATA[
 SELECT 
       T.DEAL_ORDE,
       T.DEAL_TYPE_CODE,
       T.DEAL_TYPE_NAME,
       T.SOURCE_CODE,
       T.SOURCE_NAME,
       T.TAR_CODE,
       T.TAR_NAME,
       T.KEP_NO,
       T.MAT_NO,
       T.RESULT_NO,
       T.ZY_PLAN_ID,
       T.WO_ID,
       T.PRO_PLAN_ID,
       T.JG_GROUP_ID,
       T.PRO_PLAN_ID1,
       T.JG_GROUP_ID1,
       T.PLINE_CODE,
       T.PLINE_NAME,
       T.MAT_ORIGIN_CODE,
       T.MAT_ORIGIN_NAME,
       T.SOURE_CODE,
       T.SOURE_NAME,
       T.JUDGE_STOVE_NO,
       T.BATCH_NO,
       T.BL_WL_ID,
       T.BL_WL_DESC,
       T.MIN_D,
       T.MIN_H,
       T.CODE_JG,
       T.GRADECODE,
       T.GRADENAME,
       T.STEELCODE,
       T.STEELNAME,
       T.MODEL_CODE,
       T.MODEL_DESC,
       T.OUTDIAMETER,
       T.WALLTHICK,
       T.SPEC_JG,
       T.SPEC_JG_DESC,
      (SELECT B.BASENAME
          FROM COM_BASE_INFO B
         WHERE B.BASECODE = T.STYLE_JG
           AND B.VALIDFLAG = '1') STYLE_JG,
       T.DIAMETER,
       T.CHECK_J_VAL,
       T.AIMLENGTH,
       T.SINGLEWEIGHT,
       T.MONITORDEMAND,
       T.IF_MONITOR_JG,
       T.PRDCR_NO,
       T.PRODUCER,
       TO_CHAR(T.PRODUCER_TIME, 'YYYY-MM-DD HH24:MI:SS') PRODUCER_TIME,
       T.MACH_NO,
       T.MACH_NM,
       T.DEAL_NUM,
       T.DEAL_WT,
       T.BAL_YEAR_MONTH,
       TO_CHAR(T.F_IN_TIME, 'YYYY-MM-DD HH24:MI:SS') F_IN_TIME,
       TO_CHAR(T.DEAL_TIME, 'YYYY-MM-DD HH24:MI:SS') DEAL_TIME,
       (SELECT B.STORAGE_NAME FROM YDM_BS_STORAGE B WHERE B.STORAGE_NO=T.STORAGE_NO AND B.VALIDFLAG='1') STORAGE_NO,
       T.LOCATION_NO,
       T.STORAGE_ATTR,
       T.STORAGE_ATTR_NAME,
       T.STORAGE_TYPE_NO,
       T.STORAGE_TYPE_NAME,
       T.TAR_STORAGE_NO,
       T.TAR_LOCATION_NO,
       T.TAR_KEP_NO,
       T.TAR_STORAGE_ATTR,
       T.TAR_STORAGE_ATTR_NAME,
       T.TAR_STORAGE_TYPE_NO,
       T.TAR_STORAGE_TYPE_NAME,
       DECODE(TAR_REC_FLAG, '0', '未接收', '1', '已接收') TAR_REC_FLAG,
       DECODE(HAND_FLAG, '0', '自动', '1', '人工') HAND_FL,
       (SELECT B.BASENAME
          FROM COM_BASE_INFO B
         WHERE B.BASECODE = T.DEMAND_DETECTION
           AND B.VALIDFLAG = '1') DEMAND_DETECTION,
       (SELECT B.BASENAME
          FROM COM_BASE_INFO B
         WHERE B.BASECODE = T.DEMAND_BONDERIZING
           AND B.VALIDFLAG = '1') DEMAND_BONDERIZING,
       (SELECT B.BASENAME
          FROM COM_BASE_INFO B
         WHERE B.BASECODE = T.DEMAND_COPPER
           AND B.VALIDFLAG = '1') DEMAND_COPPER,
       (SELECT B.BASENAME
          FROM COM_BASE_INFO B
         WHERE B.BASECODE = T.DEMAND_BLAST
           AND B.VALIDFLAG = '1') DEMAND_BLAST,
       T.CUST_ALPHA_NO,
       T.ORDER_SPECIAL_DESC,
       T.ALPHA_CODE,
       T.DETER_NO,
       T.DETER_RESULTS,
       T.COL_OPERATOR,
       T.MEMO,
       T.CREATE_NAME,
       TO_CHAR(T.CREATE_TIME, 'YYYY-MM-DD HH24:MI:SS') CREATE_TIME,
       T.UPDATE_NAME,
       TO_CHAR(T.UPDATE_TIME, 'YYYY-MM-DD HH24:MI:SS') UPDATE_TIME,
       (SELECT B.BASENAME FROM COM_BASE_INFO B WHERE B.BASECODE=T.PRODUCT_FLAG AND B.VALIDFLAG='1') PRODUCT_FLAG,
       (SELECT B.BASENAME FROM COM_BASE_INFO B WHERE B.BASECODE=T.MAT_STATUS AND B.VALIDFLAG='1') MAT_STATUS,
       T.DETER_STATUS,
       T.CODE_JG_BL,
       T.CRAFT_FILE_NO,
       T.CRAFT_SEQ,
       T.BELONG_CODE,
       T.BELONG_NAME,
       DECODE(T.COAT_TYPE,'1','镀铜','2','磷化','/') COAT_TYPE,
       DECODE(T.QCM_STAUS,'00','合格','10','废品','11','待处理','/') QCM_STAUS,
       NVL(T.USED_NUM,0) USED_NUM,
       NVL(T.USED_WT,0) USED_WT,
       DECODE(T.OUT_FLAG,'1','补录出库','2','领用出库','正常出库') OUT_FLAG,
       T.JG_ORDERNO,
       T.ORDER_NO||'/'||T.ORDER_SEQ ORDER_NO,
       T.DELIVERY_NO,T.ORD_LN_DLY_PK
 FROM COUPLING_MAT_DEAL T
 WHERE 1=1 
       ]]>
	</query>
<query id="FrmDealOut.getQueryOrder" desc="查询接箍合同表">		
        <![CDATA[
        SELECT 
       T.JG_ORDERNO,
       T.ORDER_NO,
       T.ORDER_SEQ,
       T.DELIVERY_NO,
       T.BUYER_ID,
       T.BUYER_NAME,
       TO_CHAR(T.DELVRY_BDATE, 'YYYY-MM-DD HH24:MI:SS') DELVRY_BDATE,
       TO_CHAR(T.DELVRY_EDATE, 'YYYY-MM-DD HH24:MI:SS') DELVRY_EDATE,
       T.ORDERCONTACT,
       T.MONITORDEMAND,
       T.IF_MONITOR_JG,
       T.PRDCR_NO,
       T.PSC,
       T.MSC,
       T.INDEX_SEQ,
       T.CODE_JG,
       T.STEELCODE,
       T.STEELNAME,
       T.OUTDIAMETER,
       T.WALLTHICK,
       T.AIMWALLTHICK,
       T.MODEL_CODE,
       T.AIMLENGTH,
       T.SINGLEWEIGHT,
       T.ORDERWEIGHT,
       T.ORDERNUM,
       TO_CHAR(T.LATEST_PROD_DATE, 'YYYY-MM-DD HH24:MI:SS') LATEST_PROD_DATE,
       T.MATCHWEIGHT,
       T.MATCHNUM,
       T.IFBUYPLAN,
       T.BUYPLANID,
       T.BUYPLANWEIGHT,
       T.BUYPLANNUM,
       T.JGORDERSTATUS,
       T.CREATE_NAME,
       TO_CHAR(T.CREATE_TIME, 'YYYY-MM-DD HH24:MI:SS') CREATE_TIME,
       T.UPDATE_NAME,
       TO_CHAR(T.UPDATE_TIME, 'YYYY-MM-DD HH24:MI:SS') UPDATE_TIME,
       T.GROUP_JGX,
       T.JGWT_BLREQ,
       TO_CHAR(T.ISSUED_TIME, 'YYYY-MM-DD HH24:MI:SS') ISSUED_TIME,
       T.SPEC_JG,
       T.SPEC_JG_DESC,
       T.MODEL_DESC,
       T.STYLE_JG,
       T.DIAMETER,
       T.CHECK_J_VAL,
       T.ORD_LN_DLY_PK,
      (SELECT B.BASENAME
          FROM COM_BASE_INFO B
         WHERE B.BASECODE = T.DEMAND_DETECTION
           AND B.VALIDFLAG = '1') DEMAND_DETECTION,
       (SELECT B.BASENAME
          FROM COM_BASE_INFO B
         WHERE B.BASECODE = T.DEMAND_BONDERIZING
           AND B.VALIDFLAG = '1') DEMAND_BONDERIZING,
       (SELECT B.BASENAME
          FROM COM_BASE_INFO B
         WHERE B.BASECODE = T.DEMAND_COPPER
           AND B.VALIDFLAG = '1') DEMAND_COPPER,
       (SELECT B.BASENAME
          FROM COM_BASE_INFO B
         WHERE B.BASECODE = T.DEMAND_BLAST
           AND B.VALIDFLAG = '1') DEMAND_BLAST,
       T.PRO_PLAN_ID,
       T.KEY_JG,
       T.JG_GROUP_ID,
       T.FINAL_USER,
       T.FINAL_USER_DESC,
       T.IF_JG_SALEORD,
       T.PRO_PLAN_ID_S,
       T.WO_ID,
       T.KEY,
       T.STATUS,
       T.HANGKC_NUM,
      (SELECT MIN(S.PLINE_NAME) FROM PLN_ORDER_JGX_S S WHERE S.ORD_LN_DLY_PK=T.ORD_LN_DLY_PK) GOWHERE_NAME,
      M.CODE_JG_BL
 FROM PLN_ORDER_JG T,PLN_GX_JG_M M
 WHERE 1=1
 AND T.PRO_PLAN_ID=M.PRO_PLAN_ID
          ]]>
	</query>
	<query id="FrmDealOut.AddDealResult" desc="新增交易信息">
		<![CDATA[ INSERT INTO COUPLING_MAT_DEAL(
        DEAL_ORDE,
        DEAL_TYPE_CODE,
        DEAL_TYPE_NAME,
        SOURCE_CODE,
        SOURCE_NAME,
        TAR_CODE,
        TAR_NAME,
        KEP_NO,
        MAT_NO,
        RESULT_NO,
        ZY_PLAN_ID,
        WO_ID,
        PRO_PLAN_ID,
        JG_GROUP_ID,
        PRO_PLAN_ID1,
        JG_GROUP_ID1,
        PLINE_CODE,
        PLINE_NAME,
        MAT_ORIGIN_CODE,
        MAT_ORIGIN_NAME,
        SOURE_CODE,
        SOURE_NAME,
        JUDGE_STOVE_NO,
        BATCH_NO,
        BL_WL_ID,
        BL_WL_DESC,
        MIN_D,
        MIN_H,
        CODE_JG,
        GRADECODE,
        GRADENAME,
        STEELCODE,
        STEELNAME,
        MODEL_CODE,
        MODEL_DESC,
        OUTDIAMETER,
        WALLTHICK,
        SPEC_JG,
        SPEC_JG_DESC,
        STYLE_JG,
        DIAMETER,
        CHECK_J_VAL,
        AIMLENGTH,
        SINGLEWEIGHT,
        MONITORDEMAND,
        IF_MONITOR_JG,
        PRDCR_NO,
        PRODUCER,
        PRODUCER_TIME,
        MACH_NO,
        MACH_NM,
        DEAL_NUM,
        DEAL_WT,
        BAL_YEAR_MONTH,
        F_IN_TIME,
        DEAL_TIME,
        STORAGE_NO,
        LOCATION_NO,
        STORAGE_ATTR,
        STORAGE_ATTR_NAME,
        STORAGE_TYPE_NO,
        STORAGE_TYPE_NAME,
        TAR_STORAGE_NO,
        TAR_LOCATION_NO,
        TAR_KEP_NO,
        TAR_STORAGE_ATTR,
        TAR_STORAGE_ATTR_NAME,
        TAR_STORAGE_TYPE_NO,
        TAR_STORAGE_TYPE_NAME,
        TAR_REC_FLAG,
        HAND_FLAG,
        DEMAND_COPPER,
        DEMAND_DETECTION,
        DEMAND_BLAST,
        DEMAND_BONDERIZING,
        CUST_ALPHA_NO,
        ORDER_SPECIAL_DESC,
        ALPHA_CODE,
        DETER_NO,
        DETER_RESULTS,
        COL_OPERATOR,
        MEMO,
        CREATE_NAME,
        CREATE_TIME,
        PRODUCT_FLAG,
        MAT_STATUS,
        DETER_STATUS,
        CODE_JG_BL,
        CRAFT_FILE_NO,
        CRAFT_SEQ,
        BELONG_CODE,
        BELONG_NAME,
        COAT_TYPE,MAT_NO_XH,OUT_FLAG,JG_ORDERNO,ORDER_NO,ORDER_SEQ,DELIVERY_NO,ORD_PK,ORD_LN_PK,ORD_LN_DLY_PK)
 VALUES( 
        '#DEAL_ORDE#',
        '#DEAL_TYPE_CODE#',
        '#DEAL_TYPE_NAME#',
        '#SOURCE_CODE#',
        '#SOURCE_NAME#',
        '#TAR_CODE#',
        '#TAR_NAME#',
        '#KEP_NO#',
        '#MAT_NO#',
        '#RESULT_NO#',
        '#ZY_PLAN_ID#',
        '#WO_ID#',
        '#PRO_PLAN_ID#',
        '#JG_GROUP_ID#',
        '#PRO_PLAN_ID1#',
        '#JG_GROUP_ID1#',
        '#PLINE_CODE#',
        '#PLINE_NAME#',
        '#MAT_ORIGIN_CODE#',
        '#MAT_ORIGIN_NAME#',
        '#SOURE_CODE#',
        '#SOURE_NAME#',
        '#JUDGE_STOVE_NO#',
        '#BATCH_NO#',
        '#BL_WL_ID#',
        '#BL_WL_DESC#',
        '#MIN_D#',
        '#MIN_H#',
        '#CODE_JG#',
        '#GRADECODE#',
        '#GRADENAME#',
        '#STEELCODE#',
        '#STEELNAME#',
        '#MODEL_CODE#',
        '#MODEL_DESC#',
        '#OUTDIAMETER#',
        '#WALLTHICK#',
        '#SPEC_JG#',
        '#SPEC_JG_DESC#',
        '#STYLE_JG#',
        '#DIAMETER#',
        '#CHECK_J_VAL#',
        '#AIMLENGTH#',
        '#SINGLEWEIGHT#',
        '#MONITORDEMAND#',
        '#IF_MONITOR_JG#',
        '#PRDCR_NO#',
        '#PRODUCER#',
        SYSDATE,
        '#MACH_NO#',
        '#MACH_NM#',
        '#DEAL_NUM#',
        '#DEAL_WT#',
        '#BAL_YEAR_MONTH#',
        SYSDATE,
        SYSDATE,
        '#STORAGE_NO#',
        '#LOCATION_NO#',
        '#STORAGE_ATTR#',
        '#STORAGE_ATTR_NAME#',
        '#STORAGE_TYPE_NO#',
        '#STORAGE_TYPE_NAME#',
        '#TAR_STORAGE_NO#',
        '#TAR_LOCATION_NO#',
        '#TAR_KEP_NO#',
        '#TAR_STORAGE_ATTR#',
        '#TAR_STORAGE_ATTR_NAME#',
        '#TAR_STORAGE_TYPE_NO#',
        '#TAR_STORAGE_TYPE_NAME#',
        '#TAR_REC_FLAG#',
        '#HAND_FLAG#',
        '#DEMAND_COPPER#',
        '#DEMAND_DETECTION#',
        '#DEMAND_BLAST#',
        '#DEMAND_BONDERIZING#',
        '#CUST_ALPHA_NO#',
        '#ORDER_SPECIAL_DESC#',
        '#ALPHA_CODE#',
        '#DETER_NO#',
        '#DETER_RESULTS#',
        '#COL_OPERATOR#',
        '#MEMO#',
        '#CREATE_NAME#',
        TO_DATE('#CREATE_TIME#','YYYY-MM-DD HH24:MI:SS'),
        '#PRODUCT_FLAG#',
        '#MAT_STATUS#',
        '#DETER_STATUS#',
        '#CODE_JG_BL#',
        '#CRAFT_FILE_NO#',
        '#CRAFT_SEQ#',
        '#BELONG_CODE#',
        '#BELONG_NAME#',
        '#COAT_TYPE#','#MAT_NO_XH#',
        '1','#JG_ORDERNO#','#ORDER_NO#','#ORDER_SEQ#','#DELIVERY_NO#','#ORD_PK#','#ORD_LN_PK#','#ORD_LN_DLY_PK#')
		]]>
	</query>
	<query id="FrmDealOut.AddButterResult" desc="新增位置表">
		<![CDATA[
INSERT INTO COUPLING_MAT_BUTTRESS
  (MAT_NO,
   MAT_NO_XH,
   PRODUCT_FLAG,
   MAT_STATUS,
   PRO_PLAN_ID,
   JG_GROUP_ID,
   PRO_PLAN_ID1,
   JG_GROUP_ID1,
   MACH_NO,
   MACH_NM,
   MAT_ORIGIN_CODE,
   MAT_ORIGIN_NAME,
   SOURE_CODE,
   SOURE_NAME,
   PIECES,
   WEIGHT,
   CUST_ALPHA_NO,
   ORDER_SPECIAL_DESC,
   ALPHA_CODE,
   DEAL_ORDE,
   KEP_NO,
   STORAGE_NO,
   LOCATION_NO,
   STORAGE_ATTR,
   STORAGE_ATTR_NAME,
   STORAGE_TYPE_NO,
   STORAGE_TYPE_NAME,
   MANAGEMENT_NO,
   MANAGEMENT_NAME,
   MEMO,
   CREATE_NAME,
   CREATE_TIME)
VALUES
  ('#MAT_NO#',
   '#MAT_NO_XH#',
   '#PRODUCT_FLAG#',
   '#MAT_STATUS#',
   '#PRO_PLAN_ID#',
   '#JG_GROUP_ID#',
   '#PRO_PLAN_ID1#',
   '#JG_GROUP_ID1#',
   '#MACH_NO#',
   '#MACH_NM#',
   '#MAT_ORIGIN_CODE#',
   '#MAT_ORIGIN_NAME#',
   '#SOURE_CODE#',
   '#SOURE_NAME#',
   '#PIECES#',
   '#WEIGHT#',
   '#CUST_ALPHA_NO#',
   '#ORDER_SPECIAL_DESC#',
   '#ALPHA_CODE#',
   '#DEAL_ORDE#',
   '#KEP_NO#',
   '#STORAGE_NO#',
   '#LOCATION_NO#',
   '#STORAGE_ATTR#',
   '#STORAGE_ATTR_NAME#',
   '#STORAGE_TYPE_NO#',
   '#STORAGE_TYPE_NAME#',
   '#MANAGEMENT_NO#',
   '#MANAGEMENT_NAME#',
   '#MEMO#',
   '#CREATE_NAME#',
   TO_DATE('#CREATE_TIME#','YYYY-MM-DD HH24:MI:SS'))

	]]>
	</query>
	<query id="FrmDealOut.AddMatResult" desc="新增材料表">
		<![CDATA[
		 INSERT INTO COUPLING_MAT_M(
        MAT_NO,
        RESULT_NO,
        ZY_PLAN_ID,
        WO_ID,
        PLINE_CODE,
        PLINE_NAME,
        JUDGE_STOVE_NO,
        BATCH_NO,
        BL_WL_ID,
        MIN_D,
        MIN_H,
        CODE_JG,
        GRADECODE,
        GRADENAME,
        STEELCODE,
        STEELNAME,
        MODEL_CODE,
        MODEL_DESC,
        OUTDIAMETER,
        WALLTHICK,
        SPEC_JG,
        SPEC_JG_DESC,
        STYLE_JG,
        DIAMETER,
        CHECK_J_VAL,
        AIMLENGTH,
        SINGLEWEIGHT,
        MONITORDEMAND,
        IF_MONITOR_JG,
        PRDCR_NO,
        PRODUCER,
        PRO_NUM,
        PRO_WT,
        COL_OPERATOR,
        RRO_TIME,
        PRO_SHIFT,
        PRO_GROUP,
        CREATE_NAME,
        CREATE_TIME,
        F_IN_TIME,
        BL_WL_DESC,
        MEMO,
        DEMAND_DETECTION,
        DEMAND_BLAST,
        DEMAND_BONDERIZING,
        DEMAND_COPPER,
        COAT_TYPE,
        BELONG_CODE,
        BELONG_NAME,
        CODE_JG_BL,
        CRAFT_FILE_NO,
        CRAFT_SEQ,
        JG_ORDERNO,
        DETER_STATUS,
        DETER_NO,
        DETER_RESULTS,
        FINAL_USER_DESC,
        MAT_ORIGIN_CODE,
        MAT_ORIGIN_NAME,
        SOURE_CODE,
        SOURE_NAME,
        JUDGE_STD_NAME,
        DETER_NO_SEQ)
 VALUES( 
        '#MAT_NO#',
        '#RESULT_NO#',
        '#ZY_PLAN_ID#',
        '#WO_ID#',
        '#PLINE_CODE#',
        '#PLINE_NAME#',
        '#JUDGE_STOVE_NO#',
        '#BATCH_NO#',
        '#BL_WL_ID#',
        '#MIN_D#',
        '#MIN_H#',
        '#CODE_JG#',
        '#GRADECODE#',
        '#GRADENAME#',
        '#STEELCODE#',
        '#STEELNAME#',
        '#MODEL_CODE#',
        '#MODEL_DESC#',
        '#OUTDIAMETER#',
        '#WALLTHICK#',
        '#SPEC_JG#',
        '#SPEC_JG_DESC#',
        '#STYLE_JG#',
        '#DIAMETER#',
        '#CHECK_J_VAL#',
        '#AIMLENGTH#',
        '#SINGLEWEIGHT#',
        '#MONITORDEMAND#',
        '#IF_MONITOR_JG#',
        '#PRDCR_NO#',
        '#PRODUCER#',
        '#PRO_NUM#',
        '#PRO_WT#',
        '#COL_OPERATOR#',
        TO_DATE('#RRO_TIME#','YYYY-MM-DD HH24:MI:SS'),
        '#PRO_SHIFT#',
        '#PRO_GROUP#',
        '#CREATE_NAME#',
        TO_DATE('#CREATE_TIME#','YYYY-MM-DD HH24:MI:SS'),
        TO_DATE('#F_IN_TIME#','YYYY-MM-DD HH24:MI:SS'),
        '#BL_WL_DESC#',
        '#MEMO#',
        '#DEMAND_DETECTION#',
        '#DEMAND_BLAST#',
        '#DEMAND_BONDERIZING#',
        '#DEMAND_COPPER#',
        '#COAT_TYPE#',
        '#BELONG_CODE#',
        '#BELONG_NAME#',
        '#CODE_JG_BL#',
        '#CRAFT_FILE_NO#',
        '#CRAFT_SEQ#',
        '#JG_ORDERNO#',  
        '#DETER_STATUS#',
        '#DETER_NO#',
        '#DETER_RESULTS#',
        '#FINAL_USER_DESC#',
        '#MAT_ORIGIN_CODE#',
        '#MAT_ORIGIN_NAME#',
        '#SOURE_CODE#',
        '#SOURE_NAME#',
        '#JUDGE_STD_NAME#',
        '#DETER_NO_SEQ#')
		]]>
	</query>
	<query id="FrmDealOut.queryRecFalg" desc="查询交易表该数据接收状态">
		<![CDATA[
		SELECT T.TAR_REC_FLAG FROM COUPLING_MAT_DEAL T WHERE T.DEAL_ORDE = ?
			]]>
	</query>

		<query id="FrmDealOut.queryMaxDealOrde" desc="查询最大交易单号">
	 <![CDATA[  
SELECT ? || ? ||
       LPAD(SUBSTR(NVL(MAX(T.DEAL_ORDE), '000'), -3, 3) + 1, 3, '0') AS DEAL_ORDE
  FROM COUPLING_MAT_DEAL T
 WHERE  TO_CHAR(T.CREATE_TIME,'YYYY-MM-DD')=?
 AND T.DEAL_TYPE_CODE=?
   ]]>
	</query>
		<query id="FrmDealOut.queryMaxButter" desc="查询最大交易单号">
	 <![CDATA[  
SELECT LPAD(SUBSTR(NVL(MAX(T.MAT_NO_XH), '000'), -3, 3) + 1, 3, '0') AS MAT_NO_XH
  FROM COUPLING_MAT_BUTTRESS T
 WHERE T.MAT_NO = ?
   ]]>
	</query>
		<query id="FrmDealOut.queryStorageType" desc="查询库位信息">
	 <![CDATA[ 
SELECT T.STORAGE_ATTR,
       T.STORAGE_ATTR_NAME,
       T.STORAGE_TYPE_NO,
       T.STORAGE_TYPE_NAME,
       T.MANAGEMENT_NO,
       T.MANAGEMENT_NAME,
       T.STORAGE_NO,
       T.LOCATION_NO
  FROM COUPLING_MAT_BUTTRESS T
 WHERE T.MAT_NO = ?
   AND T.MAT_NO_XH = ?
	  ]]>
	</query>
</queryMap>