query-525af226c35904dc9c91551def77d64a
TODO
Use at
- https://query.wikidata.org/sparql
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX bd: <http://www.bigdata.com/rdf#>
select distinct ?sub1 ?sub1Label ?sub2 ?sub2Label ?sub3 ?sub3Label ?sub4 ?sub4Label ?sub5 ?sub5Label
where
{
?sub1 wdt:P17 wd:Q142.
?sub1 wdt:P31/wdt:P279* wd:Q10864048.
?sub2 wdt:P131 ?sub1.
?sub2 wdt:P31/wdt:P279* wd:Q13220204.
optional
{
?sub3 wdt:P131 ?sub2.
?sub3 wdt:P31/wdt:P279* wd:Q13221722.
optional
{
?sub4 wdt:P131 ?sub3.
?sub4 wdt:P31/wdt:P279* wd:Q14757767.
optional
{
?sub5 wdt:P131 ?sub4.
?sub5 wdt:P31/wdt:P279* wd:Q15640612.
}
}
}
# service wikibase:label { bd:serviceParam wikibase:language "en". }
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v1("?sub1"):::projected
v2("?sub2"):::projected
v3("?sub3"):::projected
v4("?sub4"):::projected
v5("?sub5"):::projected
a1((" "))
a2((" "))
a3((" "))
a4((" "))
a5((" "))
c9(["wd:Q14757767"]):::iri
c5(["wd:Q10864048"]):::iri
c8(["wd:Q13221722"]):::iri
c7(["wd:Q13220204"]):::iri
c10(["wd:Q15640612"]):::iri
c2(["wd:Q142"]):::iri
v1 --"wdt:P17"--> c2
v1 --"wdt:P31"--> a1
a1 --"wdt:P279"--> c5
v2 --"wdt:P131"--> v1
v2 --"wdt:P31"--> a2
a2 --"wdt:P279"--> c7
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v3 -."wdt:P131".-> v2
v3 --"wdt:P31"--> a3
a3 --"wdt:P279"--> c8
subgraph optional1["(optional)"]
style optional1 fill:#bbf,stroke-dasharray: 5 5;
v4 -."wdt:P131".-> v3
v4 --"wdt:P31"--> a4
a4 --"wdt:P279"--> c9
subgraph optional2["(optional)"]
style optional2 fill:#bbf,stroke-dasharray: 5 5;
v5 -."wdt:P131".-> v4
v5 --"wdt:P31"--> a5
a5 --"wdt:P279"--> c10
end
end
end