Context: CREATE TABLE Order_items (product_id VARCHAR, order_id VARCHAR); CREATE TABLE Orders (order_id VARCHAR); CREATE TABLE Products (product_name VARCHAR, product_id VARCHAR)
Question: Show all product names and the number of customers having an order on each product.
Answer: SELECT T2.product_name, COUNT(*) FROM Order_items AS T1 JOIN Products AS T2 ON T1.product_id = T2.product_id JOIN Orders AS T3 ON T3.order_id = T1.order_id GROUP BY T2.product_name