Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

String to date convertion 1

Status
Not open for further replies.

Fampofo

Programmer
May 24, 2002
16
GB
Dear guys. I am trying to covert a string to date format. this field is suppose to be a date field but it is a char.
this is what I did.....

to_date(max(date_last_seen)last_att

values in the field are eg. 01/02/05
this is the error msg I get "ORA-01843: not a valid month"
can anyone help. thanks
 
[tt]To_Date(max(date_last_seen),'DD/MM/YY')[/tt] should do it, but can you be sure the format is always dd/mm/yy?

The reason you are getting 'not a valid month' is likely to be that your default data format is something like DD-MON-YYYY, according to your NLS date settings.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top