query-7f4f28c4a54fa363eae6198aa6784a07
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 ?countryLabel ?districtLabel ?townLabel ?town {
?town wdt:P1082 ?citizens. #
FILTER (?citizens > 10000)
?town wdt:P17 ?country.
?country wdt:P37 wd:Q1321.
?town wdt:P31/wdt:P279* wd:Q486972.
OPTIONAL { ?town wdt:P131 ?district }
SERVICE wikibase:label { bd:serviceParam wikibase:language "es" }
} ORDER BY ?countryLabel ?districtLabel ?townLabel
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v4("?citizens")
v6("?country")
v1("?countryLabel"):::projected
v7("?district")
v2("?districtLabel"):::projected
v5("?town"):::projected
v3("?townLabel"):::projected
a1((" "))
c13(["es"]):::literal
c8(["wd:Q486972"]):::iri
c11(["bd:serviceParam"]):::iri
c5(["wd:Q1321"]):::iri
f0[["?citizens > '10000^^xsd:integer'"]]
f0 --> v4
v5 --"wdt:P1082"--> v4
v5 --"wdt:P17"--> v6
v6 --"wdt:P37"--> c5
v5 --"wdt:P31"--> a1
a1 --"wdt:P279"--> c8
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v5 -."wdt:P131".-> v7
end
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c11 --"wikibase:language"--> c13
end