Groups of customers
Use the CUBE operator to extract the content of a pivot table from the database. Create a table with the total number of male and female customers from each country.
Deze oefening maakt deel uit van de cursus
Data-Driven Decision Making in SQL
Oefeninstructies
- Create a table with the total number of customers, of all female and male customers, of the number of customers for each country and the number of men and women from each country.
Praktische interactieve oefening
Probeer deze oefening eens door deze voorbeeldcode in te vullen.
SELECT ___, -- Extract information of a pivot table of gender and country for the number of customers
___,
___
FROM customers
GROUP BY CUBE (___, ___)
ORDER BY country;