Busy networks
IntermediateHAVINGEarthquakes (USGS, Oct 2026)
Which reporting networks (net) contributed more than 100 events? Return net and count, largest first.
Solution
SELECT net, COUNT(*) AS n
FROM quakes
GROUP BY net
HAVING COUNT(*) > 100
ORDER BY n DESC;Expected output:
Hint
WHERE filters rows before grouping; HAVING filters groups after.
Same question in Excel / Google Sheets
Pivot by net, then filter the pivot's Values to greater than 100.
Download the CSV from the datasets page. Column letters assume the CSV opens with its header in row 1.
Tip: Ctrl+Enter (⌘+Enter on Mac) checks your answer. Everything runs in your browser; nothing you type is sent anywhere.