Group by (SQL)

A GROUP BY statement in SQL specifies that a SQL SELECT statement partitions result rows into groups, based on their values in one or several columns.

This implies constraints on the columns that can appear in the associated SELECT clause.

As a general rule, the SELECT clause may only contain columns with a unique value per group.

[3] Returns a list of Department IDs along with the sum of their sales for the date of January 1, 2000.

": The following code returns the data of the above pivot table which answers the question "How many units were sold in each region for every ship date?