query-9dac02e93b5ffd11f95853a56a6268f1
defaultView:Map
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 ?consulat ?consulatLabel ?image ?coord ?loc ?locLabel WHERE {
?consulat (wdt:P31/wdt:P279*) wd:Q7843791.
{
?consulat wdt:P131 ?dep.
?dep wdt:P131 wd:Q46130.
}
UNION
{
?consulat wdt:P131 ?met.
?met wdt:P131 wd:Q16665897.
}
UNION
{
?consulat wdt:P131 ?arr.
?arr wdt:P131 wd:Q456.
}
OPTIONAL { ?consulat wdt:P18 ?image. }
OPTIONAL { ?consulat wdt:P625 ?coord. }
OPTIONAL { ?consulat wdt:P131 ?loc. }
SERVICE wikibase:label { bd:serviceParam wikibase:language "fr". }
}
ORDER BY DESC(?consulatLabel)
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v5("?arr")
v2("?consulat"):::projected
v1("?consulatLabel"):::projected
v7("?coord"):::projected
v3("?dep")
v6("?image"):::projected
v8("?loc"):::projected
v4("?met")
a1((" "))
c5(["wd:Q46130"]):::iri
c13(["fr"]):::literal
c6(["wd:Q16665897"]):::iri
c7(["wd:Q456"]):::iri
c11(["bd:serviceParam"]):::iri
c3(["wd:Q7843791"]):::iri
v2 --"wdt:P31"--> a1
a1 --"wdt:P279"--> c3
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;
v2 --"wdt:P131"--> v5
v5 --"wdt:P131"--> c7
end
subgraph union1r[" "]
style union1r fill:#abf,stroke-dasharray: 3 3;
v2 --"wdt:P131"--> v4
v4 --"wdt:P131"--> c6
end
union1r <== or ==> union1l
end
end
subgraph union0r[" "]
style union0r fill:#abf,stroke-dasharray: 3 3;
v2 --"wdt:P131"--> v3
v3 --"wdt:P131"--> c5
end
union0r <== or ==> union0l
end
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v2 -."wdt:P18".-> v6
end
subgraph optional1["(optional)"]
style optional1 fill:#bbf,stroke-dasharray: 5 5;
v2 -."wdt:P625".-> v7
end
subgraph optional2["(optional)"]
style optional2 fill:#bbf,stroke-dasharray: 5 5;
v2 -."wdt:P131".-> v8
end
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c11 --"wikibase:language"--> c13
end