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
DannyS712
.
Toggle Highlighting
SQL
SET @cutoff = (DATE_FORMAT((NOW() - INTERVAL 365 DAY),'%Y%m%d%H%i%S')); SELECT a.actor_name, rev.rev_timestamp, arc.ar_timestamp, log.log_timestamp FROM user_groups ug JOIN actor_user a ON a.actor_user = ug.ug_user JOIN revision_userindex rev ON rev.rev_id = ( SELECT rev2.rev_id FROM revision_userindex rev2 WHERE a.actor_id = rev2.rev_actor ORDER BY rev2.rev_timestamp DESC LIMIT 1 ) JOIN archive_userindex arc ON arc.ar_id = ( SELECT arc2.ar_id FROM archive_userindex arc2 WHERE a.actor_id = arc2.ar_actor ORDER BY arc2.ar_timestamp DESC LIMIT 1 ) JOIN logging_userindex log ON log.log_id = ( SELECT log2.log_id FROM logging_userindex log2 WHERE a.actor_id = log2.log_actor ORDER BY log2.log_timestamp DESC LIMIT 1 ) WHERE ug.ug_group = 'sysop' AND rev.rev_timestamp < @cutoff AND arc.ar_timestamp < @cutoff AND log.log_timestamp < @cutoff AND ug.ug_user NOT IN ( SELECT ug2.ug_user FROM user_groups ug2 WHERE ug2.ug_group = 'bureaucrat' )
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...