how is become in simple and easy steps
so here is some sample of SQL loaders .ctl file
LOAD DATA <-----------"load data instruct computer to read data from flat file or .ctl file itself"
INFILE * <---------------"using * or one can give the path of file where the flat file resides"
APPEND INTO TABLE XX_TEMP_RCIA <----"An instruction to append i.e. to add in preexisted content"
fields terminated by '|' <--"this command specify from where the new coulum has started"
TRAILING NULLCOLS <--"To trail the coulumns which had null coulumns"
(
ORIG_SYSTEM_CUSTOMER_REF "TRIM(:ORIG_SYSTEM_CUSTOMER_REF)",
CUSTOMER_NAME "TRIM(:CUSTOMER_NAME)",
ORIG_SYSTEM_ADDRESS_REF "TRIM(:ORIG_SYSTEM_ADDRESS_REF)",
ADDRESS1 "TRIM(:ADDRESS1)",
ADDRESS2 "TRIM(:ADDRESS2)",
ADDRESS3 "TRIM(:ADDRESS3)",
ADDRESS4 "TRIM(:ADDRESS4)",
CITY "TRIM(:CITY)",
COUNTY "TRIM(:COUNTY)",
STATE "TRIM(:STATE)",
PROVINCE "TRIM(:PROVINCE)",
COUNTRY "TRIM(:COUNTRY)",
POSTAL_CODE "TRIM(:POSTAL_CODE)",
SITE_USE_CODE "TRIM(:SITE_USE_CODE)",
PRIMARY_SITE_USE_FLAG "TRIM(:PRIMARY_SITE_USE_FLAG)",
CUSTOMER_STATUS "TRIM(:CUSTOMER_STATUS)",
INSERT_UPDATE_FLAG "TRIM(:INSERT_UPDATE_FLAG)",
LAST_UPDATED_BY "TRIM(:LAST_UPDATED_BY)",
LAST_UPDATE_DATE "TRIM(:LAST_UPDATE_DATE )",
CREATED_BY "TRIM(:CREATED_BY)",
CREATION_DATE "TRIM(:CREATION_DATE)",
CUSTOMER_NUMBER "TRIM(:CUSTOMER_NUMBER)",
CUSTOMER_NAME_PHONETIC "TRIM(:CUSTOMER_NAME_PHONETIC)",
CUSTOMER_CATEGORY_CODE "TRIM(:CUSTOMER_CATEGORY_CODE)",
LOCATION "TRIM(:LOCATION)",
ORG_ID "TRIM(:ORG_ID)"
)
No comments:
Post a Comment