HI All,
I have a date field coming from source file which has values like:
2/28/2009 8:03 PM Mchen
2/28/2009 8:03 PM Philip Law
My target is a DB2 Database which is TimeStamp value.
I have searched the forum.
Tried IsValid, Left, Right, Field, StringToTimeStamp but unable to convert the value to a Timestamp.
Any help is really appreciated.
Date Conversion
Moderators: chulett, rschirm, roy
Date Conversion
Thanks,
Pavan
Pavan
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
If not military time ("zulu"), then at least 24-hour clock, ideally using ISO 8601 standards (YYYY-MM-DD HH:MM:SS). You only get one format mask, but days and months can have one or two digits in them. That's why you need to force them to two digits by adding leading zeroes. Try to construct a timestamp string, using substring and concatenation techniques, that matches your default timestamp format; that's the easiest approach.
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.