query-abec237540d07d538d42e0196de4b33e
How to retreive data from external website geonames.org Is there any chance to import from this website data to wikidata? Thanks in advance. Q1942504Hello everybody, I realized that currently there're over 36.000 Italian human settlements in wikidata without located in the administrative territorial entity (P131) property but, at the same time, connected with the external website geonames.org which owns this information as 3rd level administrative entity. e.g.
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 ?item ?itemLabel ?itemDescription ?geonames WHERE {
?item wdt:P31 wd:Q486972.
?item wdt:P17 wd:Q38.
?item wdt:P1566 ?geonames
MINUS {?item wdt:P131 []}
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v2("?geonames"):::projected
v1("?item"):::projected
a1((" "))
c2(["wd:Q486972"]):::iri
c4(["wd:Q38"]):::iri
c8(["bd:serviceParam"]):::iri
c10(["#91;AUTO_LANGUAGE#93;,en"]):::literal
v1 --"wdt:P31"--> c2
v1 --"wdt:P17"--> c4
v1 --"wdt:P1566"--> v2
subgraph minus0["MINUS"]
style minus0 stroke-width:6px,fill:pink,stroke:red;
v1 --"wdt:P131"--> a1
end
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c8 --"wikibase:language"--> c10
end