Toggle navigation
Home
New Query
Recent Queries
Discuss
Database tables
Database names
MediaWiki
Wikibase
Replicas browser and optimizer
Login
History
Fork
Fork of
Commons sub-cats with Wikidata sitelinks but no WD infobox
by
Jheald
This query is marked as a draft
This query has been published
by
Jheald
.
Sub-sub-sub-categories of a Commons category, with Wikidata sitelinks, but with no Wikidata infobox template
Toggle Highlighting
SQL
use commonswiki_p; SELECT DISTINCT pp.pp_value, p3.page_title, tl.tl_namespace, tl.tl_title FROM categorylinks AS c1 JOIN page AS p1 ON c1.cl_from=p1.page_id AND p1.page_namespace=14 AND p1.page_is_redirect=0 JOIN categorylinks AS c2 ON c2.cl_to = p1.page_title JOIN page AS p2 ON c2.cl_from=p2.page_id AND p2.page_namespace=14 AND p2.page_is_redirect=0 JOIN categorylinks AS c3 ON c3.cl_to = p2.page_title JOIN page AS p3 ON c3.cl_from=p3.page_id AND p3.page_namespace=14 AND p3.page_is_redirect=0 JOIN page_props AS pp ON pp.pp_page = p3.page_id AND pp.pp_propname = 'wikibase_item' LEFT JOIN templatelinks AS tl ON tl.tl_from = p3.page_id AND tl.tl_from_namespace = 14 AND tl.tl_namespace = 10 AND tl.tl_title = 'Wikidata_Infobox' LEFT JOIN templatelinks AS t3 ON t3.tl_from = p3.page_id AND t3.tl_from_namespace = 14 AND t3.tl_namespace = 10 AND tl.tl_title = 'Wikidata_Infobox/sandbox' LEFT JOIN templatelinks AS t2 ON t2.tl_from = p3.page_id AND t2.tl_from_namespace = 14 AND t2.tl_namespace = 10 AND t2.tl_title = 'Institution' WHERE c1.cl_to='Grade_I_listed_buildings_in_England' AND tl.tl_title IS NULL AND t2.tl_title IS NULL # GROUP BY p2.page_title; # LIMIT 500;
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...