Page 1 of 1

Conversion of Date format in Datastage?

Posted: Tue Jan 03, 2006 6:05 am
by kris9999
Hi,
I am new to DataStage. Can u give me suggestion regarding how to write the expression in Datastage which was given in Informatica as below,

TO_DATE('01-01-1900 12:00:00')

Thanks in Advance,

Posted: Tue Jan 03, 2006 6:23 am
by ArndW
Kris,

there is more than one answer to your question in DataStage. The function (if any) to use depends upon the target database or file format that you want. Assuming you have a string coming in, you can use the ICONV() function to parse the date and time portions into their internal formats for either computational purposes or for re-conversion to another display output format.

Posted: Tue Jan 03, 2006 6:42 am
by kcshankar
Hi Kris,
Here is an example of builtin Transform function which converts the given Timestamp format (YYYY-MM-DD HH:MM:SS) to Internal Time format.

Example: TIMESTAMP.TO.TIME('2006-01-03 16:39:59') => "59999"



regards
kcs