query-2efe9e38e4edf26807cbc25b4e669e39

rq turtle/ttl

Query #9: Units of measure

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT DISTINCT ?s ?label ?pLabel WHERE {
  ?s wdt:P31/wdt:P279* wd:Q47574 .
  ?s wdt:P31 ?p .
  MINUS {?s wdt:P31 wd:Q8142 .}
  OPTIONAL {?s rdfs:label ?label filter (lang(?label) = "en").}
  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; v1("?label"):::projected v3("?p") v2("?s"):::projected a1((" ")) c8(["bd:serviceParam"]):::iri c5(["wd:Q8142"]):::iri c4(["wd:Q47574"]):::iri c10(["#91;AUTO_LANGUAGE#93;,en"]):::literal v2 --"wdt:P31"--> a1 a1 --"wdt:P279"--> c4 v2 --"wdt:P31"--> v3 subgraph minus0["MINUS"] style minus0 stroke-width:6px,fill:pink,stroke:red; v2 --"wdt:P31"--> c5 end subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v2 -."rdfs:label".-> v1 end subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c8 --"wikibase:language"--> c10 end