VeloDB Cloud
SQL Manual
Functions
date-time-functions
day

day

Description

Syntax:

INT DAY(DATETIME date)

This function fetches the day information from the date, and returns values ranging from 1 to 31.

The parameter is of DATE or DATETIME type.

Example

mysql> select day('1987-01-31');
+----------------------------+
| day('1987-01-31 00:00:00') |
+----------------------------+
|                         31 |
+----------------------------+

Keywords

DAY