query-86f4eff50dea692cd01ef8c9869e1ec0

rq turtle/ttl

Settlements in Moldova without EN description SELECT DISTINCT ?settlement ?settlementLabel ?settlementDescriptionEN WHERE { VALUES ?type {wd:Q3957 wd:Q515 wd:Q532 wd:Q486972 wd:Q4229812} ?settlement wdt:P31 ?type .
?settlement wdt:P17 wd:Q217 . ?article schema:about ?settlement . OPTIONAL { ?settlement schema:description ?settlementDescriptionEN } FILTER (!BOUND(?settlementDescriptionEN)) SERVICE wikibase:label { bd:serviceParam wikibase:language "en,ro" } } LIMIT 50

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#>
# Settlements in Moldova without EN description
SELECT DISTINCT ?settlement ?settlementLabel ?settlementDescriptionEN WHERE {
  VALUES ?type {wd:Q3957 wd:Q515 wd:Q532 wd:Q486972 wd:Q4229812}
  ?settlement wdt:P31 ?type .   
  ?settlement wdt:P17 wd:Q217 . 
  ?article schema:about ?settlement .
    OPTIONAL { ?settlement schema:description ?settlementDescriptionEN  }
    FILTER (!BOUND(?settlementDescriptionEN))
  SERVICE wikibase:label { bd:serviceParam wikibase:language "en,ro" }
}
LIMIT 50

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v4("?article") v3("?settlement"):::projected v1("?settlementDescriptionEN"):::projected v2("?type") c9(["en,ro"]):::literal c7(["bd:serviceParam"]):::iri c3(["wd:Q217"]):::iri f0[["not bound(?settlementDescriptionEN)"]] f0 --> v1 bind1[/VALUES ?type/] bind1-->v2 bind10(["wd:Q3957"]) bind10 --> bind1 bind11(["wd:Q515"]) bind11 --> bind1 bind12(["wd:Q532"]) bind12 --> bind1 bind13(["wd:Q486972"]) bind13 --> bind1 bind14(["wd:Q4229812"]) bind14 --> bind1 v3 --"wdt:P31"--> v2 v3 --"wdt:P17"--> c3 v4 --"schema:about"--> v3 subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v3 -."schema:description".-> v1 end subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c7 --"wikibase:language"--> c9 end