Mega Code Archive

 
Categories / MySQL Tutorial / Date Time Functions
 

DAYOFMONTH(date) returns the day of the month for date, in the range 0 to 31

DAY() is a synonym for DAYOFMONTH(). mysql> mysql> SELECT DAYOFMONTH('1998-02-03'); +--------------------------+ | DAYOFMONTH('1998-02-03') | +--------------------------+ |                        3 | +--------------------------+ 1 row in set (0.00 sec) mysql>