Hi all, I am using SQL Loader to transfer data from a text file (variable length, tab delimited) onto a table. I have a date field in the table and the corresponding value in the text file is like "2002-04-01 00:00:00".
This is the format in my control file :
(Resrv_date DATE "YYYY-MM-DD HH24:MM:SS")
But, I get the error :
Record1 - Rejected - Error on table xxx, column RESRV_DATE. Field in data file exceeds maximum length.
But when I exp/imp the data or use SQL's DTS, all works fine. Any help is greatly appreciated.
Here is my control file :
INSERT INTO TABLE test_bam_util
FIELDS TERMINATED BY '\t'
(resrv_date DATE "YYYY-MM-DD HH24:MM:SS",
If I use FIELDS TERMINATED BY WHITESPACE instead of '\t', I am able to get the data into the table, but the date data "2002-04-01 00:00:00" gets spilt into 2 seperate fields - "2002-04-01" and "00:00:00" - because of the space and hence in my table, the values I have are like :
resrv_date = "2002-04-01 00:00:00"
router = "00:00:00"
When I used the TO_DATE() functionality here, as in
resrv_date DATE "TO_DATE(:resrv_date,'YYYY-MM-DD HH24:MI:SS')", this is the error I get :
ORA-01821: date format not recognized