Hi there, Little help needed. I am dealing with a pipe delimited file ex:
Transaction|Place|RDATE|Type
Manual|Chicago|1986-07-14 00:00:00.000|Failed
Manual|NULL|NULL|Failed
My control file look like this:
Fields terminated by '|' optionally enclosed by '"'
{
Transaction,
Place NULLIF Place='NULL'),
RDATE "To_DATE RDATE, 'YYYY-MM-DD HH24:MI:SS') NULLIF RDATE='NULL')",
TYPE
)
For some reason SQL loader is not liking this line:
RDATE "To_DATE RDATE, 'YYYY-MM-DD HH24:MI:SS') NULLIF RDATE='NULL')"
I am getting error:
Record 1: Rejected - Error on table XXX, column RDATE
How can I handle date conversion (mind this data file is from SQL server) and possible string 'NULL' values for same data element i.e. RDATE. In other words I can receive string 'NULL' or DATE as shown above in RDATE field.
Thx
Al
Transaction|Place|RDATE|Type
Manual|Chicago|1986-07-14 00:00:00.000|Failed
Manual|NULL|NULL|Failed
My control file look like this:
Fields terminated by '|' optionally enclosed by '"'
{
Transaction,
Place NULLIF Place='NULL'),
RDATE "To_DATE RDATE, 'YYYY-MM-DD HH24:MI:SS') NULLIF RDATE='NULL')",
TYPE
)
For some reason SQL loader is not liking this line:
RDATE "To_DATE RDATE, 'YYYY-MM-DD HH24:MI:SS') NULLIF RDATE='NULL')"
I am getting error:
Record 1: Rejected - Error on table XXX, column RDATE
How can I handle date conversion (mind this data file is from SQL server) and possible string 'NULL' values for same data element i.e. RDATE. In other words I can receive string 'NULL' or DATE as shown above in RDATE field.
Thx
Al