In a formula-type column, the YEAR_QUARTER() function displays the year and quarter of a date-type column.
-
Function name:
YEAR_QUARTER()
Syntax
YEAR_QUARTER(date_column)
Calling function parameters in TimeTonic:
- $field_name = field (link, linked table column, number, selection, formula, text...).
- "free text" = free text to add in quotes.
- do not use quotes for numbers.
Parameters
| Parameter | Description |
|---|---|
date_column |
The date-type column from which you want the year and quarter. |
Example
YEAR_QUARTER($Date)
The column returns the year and quarter corresponding to the date.
Return type
The function returns the year and quarter of the date.
The output format type of the result can be configured in the output field options of the formula editor. For more details, see Output format options in the Formula Column article.
Business use case
YEAR_QUARTER() serves as a quarterly reporting key across multiple fiscal years: comparing Q2 from one year to another.
Best practice
Placing the year before the quarter ensures correct chronological sorting when transitioning from one year to the next.