Mer-No.02 合并、采集添加新的字段

PS_BROWSELOG     -->  broad原始数据中位置为36、37,对应的产生csv为216、217

PS_MMSLOG            -->  broad原始数据中位置为39、40,对应的产生csv为216、217   

PS_EMAILLOG         -->  broad原始数据中位置为37、38,对应的产生csv为216、217 
PS_SIPREGLOG       -->  broad原始数据中位置为32、33,对应的产生csv为216、217 
PS_GBIUPSLO         -->  broad原始数据中位置为26,对应的产生csv为222
PS_RSTPLOG           -->  broad原始数据中位置为32、33,对应的产生csv为216、217 

 

1、修改CFG_SYS_BROAD_GROUP表

 

 

UPDATE CFG_SYS_BROAD_GROUP SET NUM_OUT_FIELDS = '223' WHERE ID = 'L0501'

 

 2、修改表CFG_SYS_BROAD_FIELD表

 

 

INSERT INTO CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, OUTPUT_SERIAL) VALUES ('10131217', '1013',	'40',	'1', '217');
INSERT INTO CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, OUTPUT_SERIAL) VALUES ('10131216', '1013',	'39',	'1', '216');
INSERT INTO CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, OUTPUT_SERIAL) VALUES ('10171216', '1017',	'32',	'1', '216');
INSERT INTO CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, OUTPUT_SERIAL) VALUES ('10171217', '1017',	'33',	'1', '217');
INSERT INTO CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, OUTPUT_SERIAL) VALUES ('10051216', '1005',	'37',	'1', '216');
INSERT INTO CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, OUTPUT_SERIAL) VALUES ('10051217', '1005',	'38',	'1', '217');
INSERT INTO CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, OUTPUT_SERIAL) VALUES ('10191216', '1019',	'32',	'1', '216');
INSERT INTO CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, OUTPUT_SERIAL) VALUES ('10191217', '1019',	'33',	'1', '217');
INSERT INTO CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, OUTPUT_SERIAL) VALUES ('10071222', '1007',	'26',	'1', '222');
INSERT INTO CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, OUTPUT_SERIAL) VALUES ('10021217', '1002',	'37',	'1', '217');
INSERT INTO CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, OUTPUT_SERIAL) VALUES ('10021216', '1002',	'36',	'1', '216');
 

3、修改dic_vendor_field_def

 

 

insert into dic_vendor_field_def (ID, PERF_CLASS, FIELD_ID, SERIAL, FIELD_TYPE, FIELD_VENDOR_LABEL, FIELD_NAME, TABLE_NAME, TABLE_COLUMN, TABLE_COLUMN_TYPE, FIELD_FORMULA, IS_AVAILABLE, IS_INDEX, IND_TABLE_NAME, IND_TABLE_COLUMN, IND_TABLE_COLUMN_TYPE, SQLLDR_DATATYPE, GROUP_NAME, REMARK, PROJECTIONS, ISJUMP)
values (50000222, 'L0501', 'MC0101840219', 219, 1, 222, 'APN_IU', 'perf_o_tdr_v1', 'APN_IU', 'char', '', 3, 0, '', '219', '', '', '', '', 'L0513,L0506', 1);
  

 

insert into CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, REMARK, OUTPUT_SERIAL)
values ('10131217', '1013', '40', 1, '', 217);

insert into CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, REMARK, OUTPUT_SERIAL)
values ('10131216', '1013', '39', 1, '', 216);

insert into CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, REMARK, OUTPUT_SERIAL)
values ('10171216', '1017', '32', 1, '', 216);

insert into CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, REMARK, OUTPUT_SERIAL)
values ('10171217', '1017', '33', 1, '', 217);

insert into CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, REMARK, OUTPUT_SERIAL)
values ('10051216', '1005', '37', 1, '', 216);

insert into CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, REMARK, OUTPUT_SERIAL)
values ('10051217', '1005', '38', 1, '', 217);

insert into CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, REMARK, OUTPUT_SERIAL)
values ('10191216', '1019', '32', 1, '', 216);

insert into CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, REMARK, OUTPUT_SERIAL)
values ('10191217', '1019', '33', 1, '', 217);

insert into CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, REMARK, OUTPUT_SERIAL)
values ('10071222', '1007', '26', 1, '', 222);

insert into CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, REMARK, OUTPUT_SERIAL)
values ('10021217', '1002', '37', 1, '', 217);

insert into CFG_SYS_BROAD_FIELD (ID, FILE_ID, MAP_FORMULA, MAP_TYPE, REMARK, OUTPUT_SERIAL)
values ('10021216', '1002', '36', 1, '', 216);

4、修改代码

 

package com.metarnet.VASROAM.formula;

import java.util.Map;

public class GetApnName extends FormulaAbstract {
	@Override
	public String getResult(Map<String, String> pMap, String szLine, String oldValue) {
//		if(oldValue == null){
//			return null ;
//		}else {
//			return oldValue.toLowerCase() ;
//		}
		
		// modity by shma1664 2012年5月11日 09:31:30
		if(oldValue != null && oldValue.length() != 0 && !oldValue.equals("")) {
			return oldValue ;
		} else {
			String apn_iu = pMap.get(this.params[0]);
			if(apn_iu != null && apn_iu.length() != 0 && !apn_iu.equals("")) {
				return apn_iu;
			}
		}
		
		return null;
		
	}
}
 

 

你可能感兴趣的:(合并、采集添加新的字段)