Oracle Time Stamp conversion
Moderators: chulett, rschirm, roy
Oracle Time Stamp conversion
I am building a hash file that must contain a date in the format yyyy-mm-dd. When I do the seelct statement from my Oracle DB in either a date or timestamp format the field does not populate into the hash file. If I pull the date into my hash file as a varchar is pulls the date in the format dd-MMM-YY (the mmm is the three digit month abreviation jan for january). Is there a way to convert this in either my sql select or in a transformer so that it loads into the hash in the yyyy-mm-dd date format.
Re: Oracle Time Stamp conversion
What about using TO_CHAR(date_column, 'YYYY-MM-DD') in your Oracle SQL statement.als110 wrote:I am building a hash file that must contain a date in the format yyyy-mm-dd. When I do the seelct statement from my Oracle DB in either a date or timestamp format the field does not populate into the hash file. If I pull the date into my hash file as a varchar is pulls the date in the format dd-MMM-YY (the mmm is the three digit month abreviation jan for january). Is there a way to convert this in either my sql select or in a transformer so that it loads into the hash in the yyyy-mm-dd date format.
Ogmios
In theory there's no difference between theory and practice. In practice there is.