MulaiMulai sekarang secara gratis

Number of customers

You have to give an overview of the number of customers for a presentation.

Latihan ini adalah bagian dari kursus

Data-Driven Decision Making in SQL

Lihat Kursus

Petunjuk latihan

  • Generate a table with the total number of customers, the number of customers for each country, and the number of female and male customers for each country.
  • Order the result by country and gender.

Latihan interaktif praktis

Cobalah latihan ini dengan menyelesaikan kode contoh berikut.

-- Count the total number of customers, the number of customers for each country, and the number of female and male customers for each country
SELECT country,
       gender,
	   COUNT(*)
FROM customers
___ (___, ___)
___ ___, ___; -- Order the result by country and gender
Edit dan Jalankan Kode