1) Create custom properties in WAS where application deployed.
2) Access custom properties in Java code
System.getProperty("Custom property name");
Actually in J2EE application,in each env access point & log file location is different and maintain in code is very difficult. Best option to have some properties in each env and access in code.
Tuesday, March 20, 2012
Wednesday, March 14, 2012
CSV DATA LAOD IN ORACLE
Create control file.
--------------------------------------------------------
1) Create table : CHARGE_DEPOSIT_CONFIG_UPE
with following fields
CREATE TABLE CHARGE_DEPOSIT_CONFIG_UPE
(
PART_NUMBER VARCHAR2(100 BYTE),
PARENT_PART_NO VARCHAR2(100 BYTE),
CIRCLE VARCHAR2(100 BYTE),
BILL_PLAN_REF_NUMBER VARCHAR2(100 BYTE),
PRODUCT_NAME VARCHAR2(100 BYTE),
PRODUCT_TYPE VARCHAR2(100 BYTE),
PARENT_PRODUCT_REF_NUMBER VARCHAR2(100 BYTE)
)
For example LoadData.ctl
----------------------------------------------------
options (skip=1)
LOAD DATA
INFILE 'C:\Project\General\Plans\LoadData.csv'
INSERT
INTO TABLE CHARGE_DEPOSIT_CONFIG_UPE
FIELDS TERMINATED BY ','
optionally enclosed by "'"
TRAILING NULLCOLS
(PART_NUMBER,
PARENT_PART_NO,
CIRCLE,
BILL_PLAN_REF_NUMBER,
PRODUCT_NAME,
PRODUCT_TYPE,
PARENT_PRODUCT_REF_NUMBER
)
-----------------------------------------------------
Import data
Choose existing one
select control file
and Click on Finish button
--------------------------------------------------------
1) Create table : CHARGE_DEPOSIT_CONFIG_UPE
with following fields
CREATE TABLE CHARGE_DEPOSIT_CONFIG_UPE
(
PART_NUMBER VARCHAR2(100 BYTE),
PARENT_PART_NO VARCHAR2(100 BYTE),
CIRCLE VARCHAR2(100 BYTE),
BILL_PLAN_REF_NUMBER VARCHAR2(100 BYTE),
PRODUCT_NAME VARCHAR2(100 BYTE),
PRODUCT_TYPE VARCHAR2(100 BYTE),
PARENT_PRODUCT_REF_NUMBER VARCHAR2(100 BYTE)
)
For example LoadData.ctl
----------------------------------------------------
options (skip=1)
LOAD DATA
INFILE 'C:\Project\General\Plans\LoadData.csv'
INSERT
INTO TABLE CHARGE_DEPOSIT_CONFIG_UPE
FIELDS TERMINATED BY ','
optionally enclosed by "'"
TRAILING NULLCOLS
(PART_NUMBER,
PARENT_PART_NO,
CIRCLE,
BILL_PLAN_REF_NUMBER,
PRODUCT_NAME,
PRODUCT_TYPE,
PARENT_PRODUCT_REF_NUMBER
)
-----------------------------------------------------
Import data
Choose existing one
select control file
and Click on Finish button
Subscribe to:
Posts (Atom)