Conversion from type "timestamp" to type "dat
Moderators: chulett, rschirm, roy
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
The sample date format is 10/25/2011.
As mentioned earlier,the data type of target table in job 1 is DATE.In the Job 2,the source oracle stage in which table which got populated from job 1 is the source also has the column datatype as DATE.
I want to use ORACLE stage.
I am just using SELECT .... FROM TABLE in the source stage and while viewing the data,I am getting this conversion error.
As mentioned earlier,the data type of target table in job 1 is DATE.In the Job 2,the source oracle stage in which table which got populated from job 1 is the source also has the column datatype as DATE.
I want to use ORACLE stage.
I am just using SELECT .... FROM TABLE in the source stage and while viewing the data,I am getting this conversion error.
You never said before, that you are getting this error while read the data!!
Use to_char in the Select query and change the data type as varchar for that Column while read the data.
In the TFM use StringToDate (Col,'DD/MM/YYYY') and chage the data type as Date
I trust this should work and not sure what else missing in this!!
DS User
Use to_char in the Select query and change the data type as varchar for that Column while read the data.
In the TFM use StringToDate (Col,'DD/MM/YYYY') and chage the data type as Date
I trust this should work and not sure what else missing in this!!
DS User
Oracle DATE-format is in format Timestamp from the point of view of DataStage. To compare an Oracle-date to a date in DataStage-internal format, do the following:
- select the date-value in timestamp-format from Oracle
- use Conversion-function TimestampToDate in Transformer or DateFromTimestamp in ModifyStage
After this you can match both values in DataStage-Date-format. No implicit conversion required.
- select the date-value in timestamp-format from Oracle
- use Conversion-function TimestampToDate in Transformer or DateFromTimestamp in ModifyStage
After this you can match both values in DataStage-Date-format. No implicit conversion required.
"It is not the lucky ones are grateful.
There are the grateful those are happy." Francis Bacon
There are the grateful those are happy." Francis Bacon