Re: Casting Varchar to a date
Does this help?
mysql> select str_to_date('12/06/2013','%d/%m/%Y');
+--------------------------------------+
| str_to_date('12/06/2013','%d/%m/%Y') |
+--------------------------------------+
| 2013-06-12 |
+--------------------------------------+
1 row in set (0.05 sec)
And, you really need to store your dates a field of type DATE.
That will allow you to do "date arithmetic" on your values.
Good luck,
Barry.
Subject
Written By
Posted
Re: Casting Varchar to a date
July 01, 2013 10:04PM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.