如何将属性值传递给applicationContext.xml中的PropertyPlaceholderConfigurer bean

时间:2017-07-25 06:52:39

标签: spring spring-mvc spring-profiles

我想将环境名称动态传递给PropertyPlaceholderConfigurer bean,它不是从属性文件& default-application.properties 位于类路径

CREATE OR REPLACE PROCEDURE "SP_MM_QC_DATA_MACH_JUN"
    (PSEC VARCHAR2,
      PCAT VARCHAR2,
      PSUB VARCHAR2,
      PMACHINE VARCHAR2,
      SREFDATA OUT SYS_REFCURSOR ) as
BEGIN
    OPEN SREFDATA FOR
        select S.DESCRIPTION as SECTION, 
               MT.CODE as MACHINE_TYPE, 
               MH.MACH_NO,
               MH.ID_MM_SPINMACHINE_RW_H as ID_MM_MACHINE, 
               S.ID_MM_SPINSECTION, 
               MT.CODE    || ' - ' || MH.MACH_NO as Machine
        from MM_SPINMACHINE_H MH
        left join MM_MACHINETYPE MT 
            on MT.ID_MM_MACHINETYPE = MH.ID_MM_MACHINETYPE
        left join MM_SPINSECTION S 
            on S.ID_MM_SPINSECTION = MT.ID_MM_SPINSECTION
        where MH.REC_TYPE <> '5'
        and s.id_mm_sec = PSEC
        union all
        select ms.DESCRIPTION as section, 
               mg.group_desc as machine_type, 
               mm.machine_code as MACH_NO, 
               id_mm_machine as id_mm_machine,
               MS.ID_MM_SPINSECTION, 
               mg.group_desc || ' - ' || mm.machine_code as Machine
        from MM_MACHINE MM
        left join mm_spinsection ms
            on mm.id_mm_sec = ms.ID_MM_SPINSECTION
        left join mm_group mg 
            on mm.id_mm_group_mc_typ = mg.id_mm_group
        where mm.record_typ <> '5'
        and mm.id_mm_sec = PSEC
        order by 1,2,3;
END;

0 个答案:

没有答案