Create a gist now

Instantly share code, notes, and snippets.

Embed
What would you like to do?
SELECT repo.name_s, avg(payload.size_i)
FROM github.events AS events
INNER JOIN github.events_repo AS repo ON (events.did = repo.did)
INNER JOIN github.events_payload AS payload ON (events.did=payload.did)
WHERE events.type_s = 'PushEvent' AND payload.size_i > 2
GROUP BY repo.name_s
ORDER BY avg DESC;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment