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
Aidan9382
.
create a list of talk pages that are redirects with non-redirect archive subpages, mainly to find pages that have been moved improperly without their subpages For simplicity sakes, the archive subpages must follow the ' /Archive %(counter)d ' format to be picked up
Toggle Highlighting
SQL
select CONCAT("Talk:",SUBSTR(page_title,1,LENGTH(page_title)-10)) as basepage_title from page where page_namespace = 1 and page_is_redirect = 0 and page_random < 0.1 -- Prevent taking 50 years and SUBSTR(page_title,LENGTH(page_title)-10,11) = "/Archive_1" and exists ( select 1 from page as basepage where basepage.page_namespace = 1 and basepage.page_is_redirect = 1 and basepage.page_title = SUBSTR(page.page_title,1,LENGTH(page.page_title)-10) );
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...