Toggle navigation
Home
New Query
Recent Queries
Discuss
Database tables
Database names
MediaWiki
Wikibase
Replicas browser and optimizer
Login
History
Fork
This query is marked as a draft
This query has been published
by
KCVelaga
.
Toggle Highlighting
SQL
WITH edit_counts AS ( SELECT actor_name, COUNT(DISTINCT rev_id) AS edit_count FROM revision rev JOIN actor ON rev.rev_actor = actor.actor_id WHERE actor_user IS NOT NULL GROUP BY actor_name ) SELECT YEAR(user_registration) AS reg_year, COUNT(DISTINCT user_id) AS n_users, COUNT(DISTINCT CASE WHEN edit_count = 0 THEN user_name END) AS users_edits, COUNT(DISTINCT CASE WHEN edit_count BETWEEN 1 AND 100 THEN user_name END) AS users_1_100edits, COUNT(DISTINCT CASE WHEN edit_count BETWEEN 101 AND 500 THEN user_name END) AS user_101_500edits, COUNT(DISTINCT CASE WHEN edit_count > 500 THEN user_name END) users_above_500_edits FROM user LEFT JOIN user_groups ug ON user.user_id = ug.ug_user LEFT JOIN edit_counts ec ON ec.actor_name = user.user_name WHERE user_registration BETWEEN '20100101000000' AND '20231231235959' AND ( ug_group IS NULL OR ug_group != 'bot' ) GROUP BY reg_year ORDER BY reg_year
By running queries you agree to the
Cloud Services Terms of Use
and you irrevocably agree to release your SQL under
CC0 License
.
Submit Query
Stop Query
All SQL code is licensed under
CC0 License
.
Checking query status...