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
BilledMammal
.
Toggle Highlighting
SQL
WITH conventions AS (SELECT DISTINCT(CASE WHEN page_is_redirect = 1 THEN pl_title ELSE page_title END) AS convention FROM page JOIN categorylinks ON page_id = cl_from AND cl_to = "Wikipedia_naming_conventions" JOIN pagelinks ON pl_from = page_id AND pl_namespace = 4 WHERE page_namespace = 4 AND page_title NOT IN ("Protection_policy", "Redirect", "Categorizing_redirects", "Subpages", "Requested_moves", "Namespace", "Project_namespace", "Requested_moves/Technical_requests") ) SELECT convention, COUNT(*) FROM conventions JOIN pagelinks AS direct ON direct.pl_title = convention AND pl_namespace = 4 #LEFT JOIN page on direct.pl_from = page_id AND page_is_redirect = 1 AND page_namespace = 4 #JOIN pagelinks AS indirect ON page_title = indirect.pl_title GROUP by convention
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...