FunctionRacerProblemsRace

Buyers per Product

EasySQLSQLite

A customer may order the same product many times. Return each product once with buyers, the number of different customers who ordered it. Rows may come in any order.

Example 1

orders
idcustomer_idproduct
17pen
27pen
38pen
47ink
returns
productbuyers
ink1
pen2

Constraints

Race itor take your time

Write it in your browser, against the clock. The model query, with a note on each piece of it, comes after.

More SQL problems