Toggle navigation
Home
New Query
Recent Queries
Discuss
Database tables
Database names
MediaWiki
Wikibase
Replicas browser and optimizer
Login
History
Fork
Fork of
nlwiki Current bot accounts & inactivity
by
Bdijkstra
This query is marked as a draft
This query has been published
by
Kippenvlees1
.
Toggle Highlighting
SQL
SELECT actor_name AS 'username', ug_expiry AS 'bot expiry', MAX(rev_timestamp) AS 'last edit', (UNIX_TIMESTAMP()-UNIX_TIMESTAMP(STR_TO_DATE(MAX(rev_timestamp),'%Y%m%d%H%i%s')))/31556952 AS 'years inactive' FROM user_groups, revision, actor WHERE ug_group='bot' AND rev_actor=actor_id AND actor_user IS NOT NULL AND actor_user=ug_user GROUP BY actor_name HAVING `years inactive`>2.99 # leap days ORDER BY `last edit`
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...