Question for SQL gurus: how can I select distinct and sort by number of duplicates?
I have a table with 3 fields: zip, city, state. One row for every zip code in the US, it contains about 39,000 rows.
I want to search by city name alone. Some cities, such as "Rockford", will return many rows, in several different states.
If I do "SELECT * FROM ziplist WHERE city = ‘Rockford’", I [...]