<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<meta content="text/html;charset=UTF-8" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000099">
Ezequias Rodrigues da Rocha wrote:
<blockquote
cite="mid55c095e90609190804w1eaac2aanc660020995d3710a(at)mail(dot)gmail(dot)com"
type="cite">SELECT distinct cli.bairro, COUNT( * ) as qtd<br>
FROM base.cliente cli<br>
GROUP BY cli.cidade, cli.bairro<br>
ORDER BY 2<br>
<br>
<span style="font-weight: bold;">I noticed that I cannot use "where
qtd > 1" ok ?</span><br>
<br>
What to do ?<br>
</blockquote>
Google/read tutorial for HAVING. E.g.<br>
<br>
SELECT distinct cli.bairro, COUNT( * ) as qtd<br>
FROM base.cliente cli<br>
GROUP BY cli.cidade, cli.bairro<br>
HAVING COUNT(*) > 1<br>
<br>
Zizi<br>
</body>
</html>