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
JayCubby
.
Toggle Highlighting
SQL
SELECT page.page_title AS article_title, page.page_namespace AS article_namespace, categorylinks.cl_to AS category FROM page JOIN categorylinks ON page.page_id = categorylinks.cl_from WHERE page.page_is_redirect = 0 AND page.page_namespace = 0 AND ( -- Numerical only titles (CAST(page.page_title AS UNSIGNED) > 0 AND CAST(page.page_title AS UNSIGNED) < 10000) OR -- Titles ending with " AD" (SUBSTR(page.page_title, LENGTH(page.page_title) - 2, 3) = ' AD') ) AND ( categorylinks.cl_to = 'Years' OR categorylinks.cl_to LIKE 'Years of the %st century' OR categorylinks.cl_to LIKE 'Years of the %nd century' OR categorylinks.cl_to LIKE 'Years of the %rd century' OR categorylinks.cl_to LIKE 'Years of the %th century' OR categorylinks.cl_to = page.page_title );
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...