Hi,
I have the following date value in the input file 07/31/2008 10:00:34
When i try to load it into the oracle table it is giving me insert error. what is the format to convert using iconv and oconv.
Thanks!
date conversion
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
You're going to need substring, because you have to convert your date and time separately. In your case the time component does not require conversion so may simply be appended to the converted date.
That said, Iconv()/Oconv() is a safer approach because it automatically handles single-digit month and day values (if specified as above and the source date has delimiters).
Code: Select all
Oconv(Iconv(Field(InLink.TheTimestamp," ",1,1),"DMDY"),"D-YMD[4,2,2]") : " " : Field(InLink.TheTimestamp," ",2,1)
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.