ROUND_QUARTER
Description
Rounds the date to the beginning of the quarter, i.e. leaving the year unchanged and setting the month and day to the beginning of the quarter and setting hour, minute, second and millisecond to their base value
Syntax
ROUND_QUARTER(column)
NULL handling
If the input value is NULL, then the result is NULL as well.
Examples
[1] Round dates from the beginning of a quarter to the beginning of the quarter. | ||||||||||||||||
| ||||||||||||||||
|
[2] Round dates from the middle of a quarter to the beginning of the quarter. | ||||||||||||||
| ||||||||||||||
|
[3] Round dates from the end of a quarter to the beginning of the quarter. | ||||||||||||||
| ||||||||||||||
|