query-e47761b25f240f4cc1b6911f351c39ce

rq turtle/ttl

Cats SELECT ?item ?itemLabel ?precision ?value ?earliest ?latest WHERE { VALUES ?item {wd:Q2827148} ?item p:P569 ?stat . ?stat psv:P569 [wikibase:timePrecision ?precision; wikibase:timeValue ?value]. OPTIONAL {?stat pq:P1319 ?earliest . } OPTIONAL {?stat pq:P1326 ?latest . } filter(?precision < 9) SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } }

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX psv: <http://www.wikidata.org/prop/statement/value/>
PREFIX pq: <http://www.wikidata.org/prop/qualifier/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX bd: <http://www.bigdata.com/rdf#>
#Cats
SELECT ?item ?itemLabel ?precision ?value ?earliest ?latest
WHERE 
{
  VALUES ?item {wd:Q2827148}
  ?item p:P569 ?stat . 
  ?stat psv:P569 [wikibase:timePrecision ?precision; wikibase:timeValue ?value].
  OPTIONAL {?stat pq:P1319 ?earliest . }
  OPTIONAL {?stat pq:P1326 ?latest . }
  filter(?precision < 9)
  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; v5("?earliest"):::projected v2("?item"):::projected v6("?latest"):::projected v1("?precision"):::projected v3("?stat") v4("?value"):::projected a1((" ")) c9(["bd:serviceParam"]):::iri c11(["#91;AUTO_LANGUAGE#93;,en"]):::literal f0[["?precision < '9^^xsd:integer'"]] f0 --> v1 bind1[/VALUES ?item/] bind1-->v2 bind10(["wd:Q2827148"]) bind10 --> bind1 v2 --"p:P569"--> v3 a1 --"wikibase:timePrecision"--> v1 a1 --"wikibase:timeValue"--> v4 v3 --"p:statement/value/P569"--> a1 subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v3 -."p:qualifier/P1319".-> v5 end subgraph optional1["(optional)"] style optional1 fill:#bbf,stroke-dasharray: 5 5; v3 -."p:qualifier/P1326".-> v6 end subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c9 --"wikibase:language"--> c11 end