GROUP BY
nothing
customer
item
customer, item
Aggregate
COUNT(*)
SUM(price)
AVG(price)
MAX(price)
Filters
WHERE price >= 4
HAVING count > 1
orders (input)
id
customer
item
price
result (output)
Colours show which pile each row lands in. Struck-through rows were removed by WHERE before any grouping happened.