SQL
AخA
SELECT rev_timestamp, rev_id, rev_len, actor_name, page_namespace AS ns, page_title
FROM revision
STRAIGHT JOIN page ON page_id = rev_page
JOIN actor_revision ON actor_id = rev_actor
LEFT JOIN change_tag ON ct_rev_id = rev_id AND ct_tag_id IN (SELECT ctd_id FROM change_tag_def WHERE ctd_name = 'mw-new-redirect')
LEFT JOIN recentchanges ON rc_this_oldid = rev_id AND rc_type NOT IN (5, 6) /* RC_EXTERNAL, RC_CATEGORIZE */
WHERE rc_id IS NULL
AND ct_tag_id IS NULL /* leftover redirects don't get own RC entry */
AND actor_name NOT IN("New user message", "MediaWiki message delivery")
AND rev_timestamp > '202408'
AND page_namespace <> 2600 /* exclude Flow */
AND NOT EXISTS (
/* restored revisions are not re-inserted to RC */
SELECT 1 FROM logging_logindex
WHERE log_type = 'delete' AND log_action = 'restore'
AND log_namespace = page_namespace AND log_title = page_title
AND log_timestamp > rev_timestamp
)
ORDER BY rev_timestamp DESC;
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.