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
Naudefj
.
Toggle Highlighting
SQL
SELECT DATE(CONCAT(YEAR(rev_timestamp),"-",MONTH(rev_timestamp),"-",DAY(rev_timestamp))) AS day, log_type, COUNT(rev_timestamp) AS revisions FROM afwiktionary_p.revision_userindex WHERE rev_user_text = 'Naudefj' GROUP BY day, log_type order by day desc limit 7; SELECT CONCAT(month, '/', year) monthly, SUM(period < 7) less_than_1week, SUM(period BETWEEN 7 AND 30) 1week_to_1month, SUM(period BETWEEN 31 AND 365) 1month_to_1year, SUM(period > 365) more_than_1year FROM ( SELECT SUBSTR(first, 5, 2) month, SUBSTR(first, 1, 4) year, TIMESTAMPDIFF(DAY, first, last) period FROM ( SELECT MIN(rev_timestamp) first, MAX(rev_timestamp) last FROM afwiktionary_p.revision_userindex WHERE rev_user != 0 -- AND rev_user NOT IN (SELECT ug_user FROM user_groups WHERE ug_group = 'bot') GROUP BY rev_user ) a ) b GROUP BY monthly ORDER BY year, month;
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...