query-d7980cacd6b76549b0039018f0a66cc7

rq turtle/ttl

Simple query for one town

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX schema: <http://schema.org/>
PREFIX bd: <http://www.bigdata.com/rdf#>
# defaultView:Map
SELECT ?item ?itemLabel ?itemDescription ?geolocatie ?city ?cityLabel ?locatie ?locatieLabel ?is_een ?is_eenLabel ?layer ?article WHERE {
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],nl,fr,de,en". }
  ?item wdt:P131 wd:Q2391194, ?city;
    wikibase:sitelinks ?layer.
  OPTIONAL {
    ?article schema:about ?item;
      schema:inLanguage "nl";
      schema:isPartOf <https://nl.wikipedia.org/>.
  }
  OPTIONAL { ?item wdt:P276 ?locatie. }
  OPTIONAL { ?item wdt:P625 ?geolocatie. }
  OPTIONAL { ?item wdt:P31 ?is_een. }
}
ORDER BY (?itemLabel)

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v5("?article"):::projected v3("?city"):::projected v7("?geolocatie"):::projected v8("?is_een"):::projected v2("?item"):::projected v1("?itemLabel"):::projected v4("?layer"):::projected v6("?locatie"):::projected c6(["wd:Q2391194"]):::iri c4(["#91;AUTO_LANGUAGE#93;,nl,fr,de,en"]):::literal c2(["bd:serviceParam"]):::iri c12([https://nl.wikipedia.org/]):::iri c10(["nl"]):::literal subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c2 --"wikibase:language"--> c4 end v2 --"wdt:P131"--> c6 v2 --"wdt:P131"--> v3 v2 --"wikibase:sitelinks"--> v4 subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v5 -."schema:about".-> v2 v5 --"schema:inLanguage"--> c10 v5 --"schema:isPartOf"--> c12 end subgraph optional1["(optional)"] style optional1 fill:#bbf,stroke-dasharray: 5 5; v2 -."wdt:P276".-> v6 end subgraph optional2["(optional)"] style optional2 fill:#bbf,stroke-dasharray: 5 5; v2 -."wdt:P625".-> v7 end subgraph optional3["(optional)"] style optional3 fill:#bbf,stroke-dasharray: 5 5; v2 -."wdt:P31".-> v8 end