I need to use Oracle loader to load data to a table, but I am unable to handle how the file needs to be picked. In the Location field I have mentioned the share-path from where the file needs to be picked up(BUY_IN) and next to it I am forced to give a file's name*(OutAck_20140131_02_31_16PM.csv)*. But in the actual scenario the file name doesn't remain a constant one. How can i handle this here ?
I have pasted my table script below:
CREATE TABLE OUT.BUY_RESPONSE_TEST16
(
ORDER_CATEGORY VARCHAR2(30 BYTE),
ORIGINATING_SYS_REF_ID VARCHAR2(30 BYTE),
IBUY_ORDER_ID VARCHAR2(30 BYTE),
REQUISITION_ID VARCHAR2(30 BYTE),
ITEM_ERROR_ITEM_ID NUMBER,
ORDER_ITEM_ID NUMBER,
QUANTITY NUMBER
)
ORGANIZATION EXTERNAL
( TYPE ORACLE_LOADER
DEFAULT DIRECTORY EZBUY_IN
ACCESS PARAMETERS
( RECORDS DELIMITED BY NEWLINE
SKIP 1
BADFILE 'badfile.log'
DISCARDFILE 'discardfile.log'
NOLOGFILE
FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"'
MISSING FIELD VALUES ARE NULL
)
LOCATION (BUY_IN:'OutAck_20140131_02_31_16PM.csv')
)
REJECT LIMIT UNLIMITED
NOPARALLEL
NOMONITORING;