Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Converting date format yyyy-mm-dd to mm/dd/yyyy

659584Apr 6 2009 — edited Apr 6 2009
Hi,

I need help converting the above date format. In the database the date is stored as a VARCHAR with the format yyyy-mm-dd

but I would like it changed to DATE with the format mm/dd/yyyy. I tried the following and I keep getting invalid month

select To_date(date_value, 'mm/dd/yyyy') as date_value from table

When I try to convert it to char first before converting to date I get an invalid number error

select to_date(to_char(date_value, 'mm/dd/yyyy'), 'mm/dd/yyyy') as date_value from table

What do I do?

Thanks for your help!!!
This post has been answered by Frank Kulash on Apr 6 2009
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 4 2009
Added on Apr 6 2009
5 comments
28,091 views