Date formatting in SQL Loader [message #379363] |
Tue, 06 January 2009 03:54 |
stowelle
Messages: 6 Registered: January 2009 Location: Bristol
|
Junior Member |
|
|
Hi,
I'm currently trying to load some data into Oracle using the following SQLLDR Statement:
load data
infile 'S:\TPStats\BT Download\118247\2008\December\ERD_20081204.csv'
into table DAILYIMPORTTABLE
fields terminated by "," optionally enclosed by '"'
(text_col1 FILLER,
text_col2 FILLER,
CALLEDSERVICE,
text_col3 FILLER,
NOM_DATE "TO_DATE(:NOM_DATE,,'DD/MM/YYYY HH24:Mi:SS')",
TIME "TO_DATE(:TIME,'HH24:Mi:SS')",
Duration,
text_col4 FILLER,
text_col5 FILLER,
CLI,
BTID,
text_col6 FILLER,
text_col7 FILLER,
text_col8 FILLER,
text_col9 FILLER,
text_col10 FILLER,
text_col11 FILLER,
text_col12 FILLER)
The problem I'm having is with the field Nom_date the field in the file is in format dd/mm/yyyy. When I try to load it in the date in my file that is 04/12/2008 ie 4th December 2008 loads as 20-Aug-12. Please could somebody give me advice as its driving me mad!
Many Thanks,
Emma
|
|
|
|
|
|
Re: Date formatting in SQL Loader [message #379376 is a reply to message #379372] |
Tue, 06 January 2009 04:26 |
stowelle
Messages: 6 Registered: January 2009 Location: Bristol
|
Junior Member |
|
|
Hi
In the course of asking your question I've answered my own I was looking at the data file in excel which was displaying the date on way, when I opened it in notepad it displayed it another way and has solved my problem. Thank you very much to take time out to help me though!
Emma
|
|
|
|