QUARTER
The quarter of a date, 1 to 4.
Group: Date and time. Compatible with DAX.
Syntax
QUARTER ( <date> )
| Parameter | Type | Description |
|---|---|---|
date | Date | A date, a date with a time, or text that reads as one. |
Returns
Whole number. The quarter of the year, 1 to 4: January to March is 1.
Remarks
- A blank date gives BLANK.
- It is the calendar quarter. For a financial year that starts in another month, shift the date first, as
QUARTER ( EDATE ( date, -6 ) )for a year that starts in July. - For a label such as Q1, join it to text:
"Q" & QUARTER ( date ).
Examples
Either side of a quarter's end
EVALUATE
ROW (
"31 March", QUARTER ( DATE ( 2024, 3, 31 ) ),
"1 April", QUARTER ( DATE ( 2024, 4, 1 ) )
)
| 31 March | 1 April |
|---|---|
| 1 | 2 |
Sales months by year and quarter
Sales start in November 2023 and end in October 2026, so the first and last quarters are short.
EVALUATE
GROUPBY (
ADDCOLUMNS (
VALUES ( Sales[Month] ),
"Year", YEAR ( Sales[Month] ),
"Quarter", QUARTER ( Sales[Month] )
),
[Year],
[Quarter],
"Months", COUNTX ( CURRENTGROUP (), 1 )
)
ORDER BY [Year], [Quarter]
| Year | Quarter | Months |
|---|---|---|
| 2023 | 4 | 2 |
| 2024 | 1 | 3 |
| 2024 | 2 | 3 |
| 2024 | 3 | 3 |
| 2024 | 4 | 3 |
| 2025 | 1 | 3 |
| 2025 | 2 | 3 |
| 2025 | 3 | 3 |
| 2025 | 4 | 3 |
| 2026 | 1 | 3 |
| 2026 | 2 | 3 |
| 2026 | 3 | 3 |
| 2026 | 4 | 1 |
Related functions
MONTH, YEAR, EDATE, STARTOFQUARTER.