if you wanted to change the format of a MySQL date from YYYY-MM-DD to MM/DD/YYYY or DD/MM/YYYY format you can use the DATE_FORMAT() function as shown in the example below:
SELECT DATE_FORMAT(column_name, '%m/%d/%Y') FROM tablename
0 comments
Published on Tuesday, April 6, 2010 in database
Copyright © 2010 Logical ideas All rights reserved.
Wptheme by Paddsolutions. Blogger Template by Anshul.
No Response to "Mysql query for date format"
Post a Comment