query-d2bd2461541bccb4eed733a0d022cd08
TODO
Use at
- https://query.wikidata.org/sparql
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX schema: <http://schema.org/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?item ?itemLabel ?place ?placeLabel ?distance WHERE {
{
SELECT ?item ?place ?distance WHERE {
?item wdt:P3003 []; wdt:P625 ?coord .
MINUS { ?item ^schema:about/schema:IsPartOf <https://cs.wikipedia.org/> } .
SERVICE wikibase:around {
?place wdt:P625 ?location .
bd:serviceParam wikibase:center ?coord .
bd:serviceParam wikibase:radius "1" .
bd:serviceParam wikibase:distance ?distance .
} .
FILTER ( ?item != ?place ) .
} LIMIT 10
} .
SERVICE wikibase:label { bd:serviceParam wikibase:language "cs" } .
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v3("?coord")
v5("?distance"):::projected
v1("?item"):::projected
v4("?location")
v2("?place"):::projected
a1((" "))
a2((" "))
c5([https://cs.wikipedia.org/]):::iri
c14(["cs"]):::literal
c10(["1"]):::literal
c7(["bd:serviceParam"]):::iri
f0[["?item != ?place"]]
f0 --> v1
f0 --> v2
v1 --"wdt:P3003"--> a1
v1 --"wdt:P625"--> v3
subgraph minus1["MINUS"]
style minus1 stroke-width:6px,fill:pink,stroke:red;
a2 --"schema:about"--> v1
a2 --"schema:IsPartOf"--> c5
end
subgraph s1["http://wikiba.se/ontology#around"]
style s1 stroke-width:4px;
v2 --"wdt:P625"--> v4
c7 --"wikibase:center"--> v3
c7 --"wikibase:radius"--> c10
c7 --"wikibase:distance"--> v5
end
subgraph s2["http://wikiba.se/ontology#label"]
style s2 stroke-width:4px;
c7 --"wikibase:language"--> c14
end