query-22c35e32a1ca2c305bc393e7518bf0dc

rq turtle/ttl

Sahitya Akademi Awarded Odia books (34 Results, 16 JAN 2019) SELECT ?book ?bookLabel ?itemLabel ?year WHERE { ?book wdt:P31 wd:Q571. ?book wdt:P407 wd:Q33810. ?book wdt:P166 wd:Q172582.

?item wdt:P31 wd:Q5. ?item wdt:P800 ?book. ?item p:P166 ?statement. ?statement ps:P166 wd:Q172582. ?statement pq:P585 ?year.

SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE], en". } } ORDER BY DESC(?year)

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 pq: <http://www.wikidata.org/prop/qualifier/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX bd: <http://www.bigdata.com/rdf#>
# Sahitya Akademi Awarded Odia books (34 Results, 16 JAN 2019)
SELECT ?book ?bookLabel ?itemLabel ?year 
WHERE {
  ?book wdt:P31 wd:Q571.
  ?book wdt:P407 wd:Q33810.
  ?book wdt:P166 wd:Q172582.

  ?item wdt:P31 wd:Q5.
  ?item wdt:P800 ?book.
  ?item p:P166 ?statement.
  ?statement ps:P166 wd:Q172582.
  ?statement pq:P585 ?year.

  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE], en". }
}
ORDER BY DESC(?year)

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v2("?book"):::projected v3("?item") v4("?statement") v1("?year"):::projected c6(["wd:Q172582"]):::iri c15(["#91;AUTO_LANGUAGE#93;, en"]):::literal c13(["bd:serviceParam"]):::iri c7(["wd:Q5"]):::iri c2(["wd:Q571"]):::iri c4(["wd:Q33810"]):::iri v2 --"p:direct/P31"--> c2 v2 --"p:direct/P407"--> c4 v2 --"p:direct/P166"--> c6 v3 --"p:direct/P31"--> c7 v3 --"p:direct/P800"--> v2 v3 --"p:P166"--> v4 v4 --"p:statement/P166"--> c6 v4 --"p:qualifier/P585"--> v1 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c13 --"wikibase:language"--> c15 end