RE: Sqlldr (Problem with loading a date field)

RE: Sqlldr (Problem with loading a date field)

 

  

Raquel,

Can you change the format of your insert where you can substring the
date and time to this: to_date(substr(date_val,1,10)||'
'||substr(date_val,12,8),'YYYY-MM-DD HH24:MI:SS') ? I'm not sure how
the control file works so I'm kind of shooting in the dark here.

You should also be able to import the value into a VARCHAR2 field, but
you will need to deal then with inserting a date column, using the
VARCHAR2 data to populate the date field, then eliminate the VARCHAR2
field.

Paul Blosser
System Developer
Abanco Int'l, LLC.
847-227-2301x2421

-----Original Message-----
From: Sikyala Raquel
[mailto:oracledba-ezmlmshield-x99206216.[Email address protected]
Sent: Monday, March 05, 2007 2:36 PM
To: LazyDBA Discussion
Subject: Sqlldr (Problem with loading a date field)

I have some data I am trying to load into an Oracle table through
sqlldr. One of the fields is a date field. The following is a sample
value:

2006-10-16T16:37:59Z

In my control file the field is identified as 'DateGenerated date'. I
tried to load the data with the data type field of CHAR just to get it
into the database and I got the following error:

Record 1: Rejected - Error on table TR, column DATEGENERATED.
ORA-01861: literal does not match format string

How would I modify this field entry so that it can successfully load the
data above?

Raquel Sikyala



---------------------------------------------------------------------
TO REPLY TO EVERYBODY , PLEASE CLICK REPLY-ALL, NOT JUST REPLY
To post a dba job: http://jobs.lazydba.com
To Subscribe : http://www.LazyDBA.com
To unsubscribe: http://www.lazydba.com/unsubscribe.html



Oracle LazyDBA home page