> ## Documentation Index
> Fetch the complete documentation index at: /documents/llms.txt
> Use this file to discover all available pages before exploring further.

# month

> Returns the month for a given date.

Returns the month for a given date. The return value ranges from 1 to 12.

The `date` parameter must be of the DATE or DATETIME type.

## Syntax

```Haskell theme={null}
INT MONTH(DATETIME date)
```

## Examples

```Plain Text theme={null}
MySQL > select month('1987-01-01');
+-----------------------------+
|month('1987-01-01 00:00:00') |
+-----------------------------+
|                           1 |
+-----------------------------+
```

## keyword

MONTH


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.