6
have these tables (example)
Municipio (id, nome)
1, Santos
2, Sao Paulo
3, Rio de Janeiro
4, Florianopolis
5, Porto Alegre
6, Natal
Cliente (id, nomecliente, cidade)
1, Joao, 1
2, Pedro, 3
3, Maria, 3
4, Julio, 3
5, Mario, 1
I need to count all municipalities that have zero registered customers i executed the code below and would only sort by number of customers, but cities with customers = 0 it does not show in return, as I do to show?
SELECT COUNT(*), cidade FROM cliente GROUP BY cidade
What the
SGBD
used?– Sorack