|
I always seem to be digging around to find MySQL’s date formatting syntax, so here is a couple of common conversions…
where date is the name of your date field, and new_date is the variable name which you can use to reference the value.
| date_format String | Example |
| ‘%e/%c/%Y’ | 25/4/2009 |
| ‘%c/%e/%Y’ | 4/25/2009 |
| ‘%d/%m/%Y’ | 25/04/2009 |
| ‘%m/%d/%Y’ | 04/25/2009 |
| ‘%a %D %b %Y’ | Fri 25th Apr 2009 |
A more complete list of specifiers is available here.



| Based on a theme by Ori Pearl