I have a table with 6 columns and I want to group them by quarters of the year, so far this is my code
SELECT
DATE_TRUNC(date(timestamp_column), QUARTER),
Column_2,
Column_3,
Column_4,
MAX(column_4),
MAX(column_4)
from table
group by 1,2,3,4 order by 1 desc
This returns the dates in order but they are not grouped by quarter. Does anyone have any idea on the solution to this