query-008bd46cb1ec88f645a0cbc8b5609c64

rq turtle/ttl

Why do I get 1 as a ?unitShort… 15:02, 8 April 2020 (UTC)) talk (Loominade--(Q796758)egg white …for

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX ps: <http://www.wikidata.org/prop/statement/>
PREFIX pqv: <http://www.wikidata.org/prop/qualifier/value/>
PREFIX pq: <http://www.wikidata.org/prop/qualifier/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?ord ?ingredient ?ingredientLabel ?quantity ?unitShort ?unitLabel WHERE {
      SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
      { 
        wd:Q1039131 p:P186 ?materialStatement.
        ?materialStatement ps:P186 ?ingredient.
        OPTIONAL {
          ?materialStatement pq:P1114 ?quantity.
          ?materialStatement pqv:P1114 ?value.
          ?value wikibase:quantityUnit ?unit.
          ?unit wdt:P5061 ?unitShort.
          FILTER(LANG(?unitShort) = "en")
        }
        OPTIONAL {
          ?materialStatement pq:P1545 ?ord.
        }
      } MINUS {
        ?materialStatement pq:P518 wd:Q81727.
      }
    } ORDER BY ASC(?ord)

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v4("?ingredient"):::projected v3("?materialStatement") v1("?ord"):::projected v5("?quantity"):::projected v7("?unit") v2("?unitShort"):::projected v6("?value") c15(["wd:Q81727"]):::iri c6(["wd:Q1039131"]):::iri c2(["bd:serviceParam"]):::iri c4(["#91;AUTO_LANGUAGE#93;,en"]):::literal subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c2 --"wikibase:language"--> c4 end c6 --"p:P186"--> v3 v3 --"p:statement/P186"--> v4 subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v3 -."p:qualifier/P1114".-> v5 v3 --"p:qualifier/value/P1114"--> v6 v6 --"wikibase:quantityUnit"--> v7 v7 --"p:direct/P5061"--> v2 end subgraph optional1["(optional)"] style optional1 fill:#bbf,stroke-dasharray: 5 5; v3 -."p:qualifier/P1545".-> v1 end subgraph minus0["MINUS"] style minus0 stroke-width:6px,fill:pink,stroke:red; v3 --"p:qualifier/P518"--> c15 end