Conversion Varchar to Date datatype

Database
Enthusiast

Conversion Varchar to Date datatype

Hi All,

I have to load data from varchar column which has value like '01-AUG-09' to date column.

When i do CAST as date it is throwing below error.

Error : 2666 Invalid date supplied

Please help me in identifying the issue.

Thanks
Sen
1 REPLY
Enthusiast

Re: Conversion Varchar to Date datatype

i got the soln

SEL CAST('21-DEC-08' AS DATE FORMAT 'DD-MMM-YY')