Exercise: 28
Using Product table, find out the number of makers who produce only one model.
Solution
WITH makers AS (
SELECT maker AS Qty_model
FROM Product
GROUP BY maker
HAVING COUNT(model) = 1
)
SELECT COUNT(*)
FROM makers
Exercise: 28
Using Product table, find out the number of makers who produce only one model.
Solution
WITH makers AS (
SELECT maker AS Qty_model
FROM Product
GROUP BY maker
HAVING COUNT(model) = 1
)
SELECT COUNT(*)
FROM makers