I have this query for MySQL:
SELECT email, COUNT(*) AS Vezes FROM automovel
GROUP BY email HAVING COUNT(*)
ORDER BY 'data_cadastro' ASC
It groups all the emails together, and shows how many times they appear. I need to make it just show the number of times they repeat, but without grouping the lines.
What is it like?
Today it looks like this:
email Vezes em que aparece
pedro1@teste 1
pedro2@teste 3
I need to leave this:
email Vezes em que aparece
pedro2@teste 3
pedro1@teste 1
pedro2@teste 3
pedro2@teste 3