Hi All,
I've a column with data type Timestamp. Please let me know how I can convert it into Oracle Date format (DD-MON-YYYY]
Thanks,
Sumesh
Date conversion
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 153
- Joined: Thu May 11, 2006 1:52 am
- Location: Bangalore
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
Why do you want to? Surely if you convert it to a Date data type that's all you need to do. The Oracle Enterprise stage will accept a Date data type and process it properly.
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.
-
- Participant
- Posts: 153
- Joined: Thu May 11, 2006 1:52 am
- Location: Bangalore
The data type has been specified as Timestamp in the input data set and I need to write it to an Oracle table which has a column with Timestamp data type.
e.g. The value in the data set is 2007-10-10. My understanding says Oracle expects the above date in the format 10-OCT-2007 and without converting it to the expected format, the insert will not happen.Am I correct? If yes, I want to convert into the Oracle date format before writing to the table. How can I do this in the derivation.
Do you mean to say, the insert will happen if I make the target column data type as Date. Please clarify.
e.g. The value in the data set is 2007-10-10. My understanding says Oracle expects the above date in the format 10-OCT-2007 and without converting it to the expected format, the insert will not happen.Am I correct? If yes, I want to convert into the Oracle date format before writing to the table. How can I do this in the derivation.
Do you mean to say, the insert will happen if I make the target column data type as Date. Please clarify.
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
That's exactly what I mean to say. You could even leave it as Timestamp. They're the same to Oracle. You only need to worry about format if you are supplying string data and applying a TO_DATE function.
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.