query-8dd59edd5985e028e6c194c8f5a63e66

rq turtle/ttl


Beschreibung

--------------------------------

SELECT DISTINCT ?item ?itemLabel ?itemDescription ?Verwaltungseinheit ?Bild ?Koordinaten WHERE { ?item wdt:P31/wdt:P279* wd:Q15324. # Gewässer oder Unterklasse {?item wdt:P131 wd:Q2795.} # ... liegt in Chemnitz ... UNION {?item wdt:P131 ?Stadtteil. # ... oder einer Unter-Verwaltungseinheit von Chemnitz ?Stadtteil wdt:P131 wd:Q2795. }

OPTIONAL {?item wdt:P131 ?Verwaltungseinheit.} # liegt in der Verwaltungseinheit OPTIONAL {?item wdt:P18 ?Bild.} # Bild (optional) OPTIONAL {?item wdt:P625 ?Koordinaten.} # geographische Koordinaten (optional)

SERVICE wikibase:label { bd:serviceParam wikibase:language "de,en,[AUTO_LANGUAGE]"} }

Use at

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#>
#--------------------------------
# Beschreibung
#--------------------------------

SELECT DISTINCT ?item  ?itemLabel ?itemDescription ?Verwaltungseinheit ?Bild ?Koordinaten
WHERE
{
   ?item wdt:P31/wdt:P279* wd:Q15324.                    # Gewässer oder Unterklasse
   {?item wdt:P131 wd:Q2795.}                               # ... liegt in Chemnitz ...
   UNION
   {?item wdt:P131 ?Stadtteil.                                  # ... oder einer Unter-Verwaltungseinheit von Chemnitz
   ?Stadtteil wdt:P131 wd:Q2795. }


   OPTIONAL {?item wdt:P131 ?Verwaltungseinheit.}         # liegt in der Verwaltungseinheit
   OPTIONAL {?item wdt:P18  ?Bild.}                      # Bild (optional)
   OPTIONAL {?item wdt:P625 ?Koordinaten.}                      # geographische Koordinaten (optional)

   SERVICE wikibase:label { bd:serviceParam wikibase:language "de,en,[AUTO_LANGUAGE]"}
}

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v4("?Bild"):::projected v5("?Koordinaten"):::projected v2("?Stadtteil") v3("?Verwaltungseinheit"):::projected v1("?item"):::projected a1((" ")) c9(["bd:serviceParam"]):::iri c5(["wd:Q2795"]):::iri c3(["wd:Q15324"]):::iri c11(["de,en,#91;AUTO_LANGUAGE#93;"]):::literal v1 --"wdt:P31"--> a1 a1 --"wdt:P279"--> c3 subgraph union0[" Union "] subgraph union0l[" "] style union0l fill:#abf,stroke-dasharray: 3 3; v1 --"wdt:P131"--> v2 v2 --"wdt:P131"--> c5 end subgraph union0r[" "] style union0r fill:#abf,stroke-dasharray: 3 3; v1 --"wdt:P131"--> c5 end union0r <== or ==> union0l end subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v1 -."wdt:P131".-> v3 end subgraph optional1["(optional)"] style optional1 fill:#bbf,stroke-dasharray: 5 5; v1 -."wdt:P18".-> v4 end subgraph optional2["(optional)"] style optional2 fill:#bbf,stroke-dasharray: 5 5; v1 -."wdt:P625".-> v5 end subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c9 --"wikibase:language"--> c11 end