This tutorial explains how to use the MySQL DAY function with syntax and examples.
The MySQL DAY function returns the day portion of a date value.
The syntax for the DAY function in MySQL is:
The date or datetime value from which to extract the day.
The DAY function can be used in the following versions of MySQL:
Let's look at some MySQL DAY function examples and explore how to use the DAY function in MySQL.
For example:
This last DAY example would display the day portion of the current system date (current system date is returned by the CURDATE function).