query-5526aedcca3bcccfb1940acd2bd5a4a5
Propertiesinstance of (P31)ISO 3166-2 code (P300)
Use at
- https://query.wikidata.org/sparql
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT ?item ?ISO_code ?Label_en ?Label_de ?Label_fr ?Label_it WHERE {
{?item wdt:P31 wd:Q23058}.
{?item wdt:P300 ?ISO_code}.
OPTIONAL { ?item rdfs:label ?Label_en . FILTER (lang(?Label_en) = "en") }
OPTIONAL { ?item rdfs:label ?Label_de . FILTER (lang(?Label_de) = "de") }
OPTIONAL { ?item rdfs:label ?Label_fr . FILTER (lang(?Label_fr) = "fr") }
OPTIONAL { ?item rdfs:label ?Label_it . FILTER (lang(?Label_it) = "it") }
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v6("?ISO_code"):::projected
v3("?Label_de"):::projected
v4("?Label_en"):::projected
v2("?Label_fr"):::projected
v1("?Label_it"):::projected
v5("?item"):::projected
c6(["wd:Q23058"]):::iri
v5 --"wdt:P31"--> c6
v5 --"wdt:P300"--> v6
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v5 -."rdfs:label".-> v4
end
subgraph optional1["(optional)"]
style optional1 fill:#bbf,stroke-dasharray: 5 5;
v5 -."rdfs:label".-> v3
end
subgraph optional2["(optional)"]
style optional2 fill:#bbf,stroke-dasharray: 5 5;
v5 -."rdfs:label".-> v2
end
subgraph optional3["(optional)"]
style optional3 fill:#bbf,stroke-dasharray: 5 5;
v5 -."rdfs:label".-> v1
end