query-19b52a30c1f82fbd925f0d3458483247
TODO
Use at
- https://query.wikidata.org/sparql
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT DISTINCT ?item ?itemLabel (GROUP_CONCAT(DISTINCT ?P31Label_;separator="; ") as ?P31Label)
WHERE
{
# VALUES ?item {wd:Q75267360}
{ ?item wdt:P31/wdt:P31+ wd:Q201658 . } UNION
{ ?item wdt:P31/wdt:P31+ wd:Q659563 . } UNION
{ ?item wdt:P31/wdt:P31+ wd:Q223393 . } UNION
{ ?item wdt:P31/wdt:P31+ wd:Q188451 . } UNION
{ ?item wdt:P31/wdt:P31+ wd:Q4178140 . } UNION
{ ?item wdt:P31/wdt:P31+ wd:Q104822033 . }
?item wdt:P31 ?P31.
} GROUP BY ?item ?itemLabel
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v2("?P31")
v4("?P31Label")
v3("?P31Label_"):::projected
v1("?item"):::projected
a1((" "))
a2((" "))
a3((" "))
a4((" "))
a5((" "))
a6((" "))
c2(["wd:Q201658"]):::iri
c5(["wd:Q188451"]):::iri
c4(["wd:Q223393"]):::iri
c6(["wd:Q4178140"]):::iri
c3(["wd:Q659563"]):::iri
c7(["wd:Q104822033"]):::iri
subgraph union0[" Union "]
subgraph union0l[" "]
style union0l fill:#abf,stroke-dasharray: 3 3;
subgraph union1[" Union "]
subgraph union1l[" "]
style union1l fill:#abf,stroke-dasharray: 3 3;
subgraph union2[" Union "]
subgraph union2l[" "]
style union2l fill:#abf,stroke-dasharray: 3 3;
subgraph union3[" Union "]
subgraph union3l[" "]
style union3l fill:#abf,stroke-dasharray: 3 3;
subgraph union4[" Union "]
subgraph union4l[" "]
style union4l fill:#abf,stroke-dasharray: 3 3;
v1 --"wdt:P31"--> a6
a6 --"wdt:P31"--> c7
end
subgraph union4r[" "]
style union4r fill:#abf,stroke-dasharray: 3 3;
v1 --"wdt:P31"--> a5
a5 --"wdt:P31"--> c6
end
union4r <== or ==> union4l
end
end
subgraph union3r[" "]
style union3r fill:#abf,stroke-dasharray: 3 3;
v1 --"wdt:P31"--> a4
a4 --"wdt:P31"--> c5
end
union3r <== or ==> union3l
end
end
subgraph union2r[" "]
style union2r fill:#abf,stroke-dasharray: 3 3;
v1 --"wdt:P31"--> a3
a3 --"wdt:P31"--> c4
end
union2r <== or ==> union2l
end
end
subgraph union1r[" "]
style union1r fill:#abf,stroke-dasharray: 3 3;
v1 --"wdt:P31"--> a2
a2 --"wdt:P31"--> c3
end
union1r <== or ==> union1l
end
end
subgraph union0r[" "]
style union0r fill:#abf,stroke-dasharray: 3 3;
v1 --"wdt:P31"--> a1
a1 --"wdt:P31"--> c2
end
union0r <== or ==> union0l
end
v1 --"wdt:P31"--> v2
bind1[/"?P31Label_"/]
v3 --o bind1
bind1 --as--o v4