SQL
AخA
USE enwiki_p;
SELECT
rev_user_text AS username,
COUNT(rev_id) AS edit_count,
COUNT(CASE
WHEN (DATE(rev_timestamp) >= NOW() - INTERVAL 1 MONTH) THEN 1
ELSE null
END) AS edits_in_last_month
COUNT(CASE
WHEN (DATE(rev_timestamp) >= NOW() - INTERVAL 1 YEAR) THEN 1
ELSE null
END) AS edits_in_last_year
FROM revision_userindex
WHERE rev_user_text = 'Mr. Stradivarius'
GROUP BY rev_user_text;
By running queries you agree to the Cloud Services Terms of Use and you irrevocably agree to release your SQL under CC0 License.
All SQL code is licensed under CC0 License.