Summarizing Data Using the GROUPING SETS Operator
Writing aggregate queries is one of the most important tasks for anyone working with T-SQL. Determining the expressions required in the GROUP BY clause is not that difficult, but what do you do if you need to include different combinations of group by expressions in the same result set? Alfonso demonstrates how to use the GROUPING SETS operator to accomplish this task.
2017-12-18
4,860 reads