Results of a SELECT query can be grouped by one or more columns using the
GROUP BY statement: all results with the same value in the grouped columns are aggregated together. This generates a table of partial results, instead of one result. GROUP BY can be used in conjunction with aggregation functions using the
HAVING statement to define how non-grouped columns are aggregated.