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
Airklizz
.
Toggle Highlighting
SQL
select category.cat_title, category.cat_subcats from category inner join (select cl_grand_parent.cl_to from categorylinks as cl_grand_parent inner join (select page_id from page inner join (select category.cat_title, category.cat_subcats from category inner join (select cl_parent.cl_to from categorylinks as cl_parent inner join (select page_id from page where page_title = "Berlin" and page_namespace = 14 limit 1) as p on cl_parent.cl_from = p.page_id where not "Hidden_categories" in (select cl_hidden.cl_to from categorylinks as cl_hidden where cl_from = (select page_id from page where page_title = cl_parent.cl_to and page_namespace = 14 limit 1) ) ) as parent on parent.cl_to = category.cat_title ) as parent on parent.cat_title = cl_parent.cl_to where page_namespace = 14 limit 1) as p on cl_grand_parent.cl_from = p.page_id where not "Hidden_categories" in (select cl_hidden.cl_to from categorylinks as cl_hidden where cl_from = (select page_id from page where page_title = cl_grand_parent.cl_to and page_namespace = 14 limit 1) ) ) as grand_parent on grand_parent.cl_to = category.cat_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...