query-847d9c095d3c23fb53e2bdc3ff547d21

rq turtle/ttl

Add reference for the numberHello, how to add the reference that provided the number ?

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
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#>
SELECT ?item ?itemLabel ?year
(sample(?number) as ?number)
WHERE {
values ?item {
wd:Q384788
} .
?item p:P3872 ?statement.
?statement pq:P585 ?time.
?statement ps:P3872 ?number.
bind (YEAR(?time) AS ?year) 
SERVICE wikibase:label { bd:serviceParam wikibase:language "fr". }
MINUS { ?statement wikibase:rank wikibase:DeprecatedRank }
} group by ?year ?item ?itemLabel
order by ?item desc (?year)

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v3("?item"):::projected v6("?number"):::projected v3("?statement") v4("?time") v6("?year"):::projected c5(["bd:serviceParam"]):::iri c9(["wikibase:DeprecatedRank"]):::iri c7(["fr"]):::literal bind0[/VALUES ?item/] bind0-->v3 bind00(["wd:Q384788"]) bind00 --> bind0 v3 --"p:P3872"--> v3 v3 --"p:qualifier/P585"--> v4 v3 --"p:statement/P3872"--> v6 bind1[/"year-from-dateTime(?time)"/] v4 --o bind1 bind1 --as--o v6 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c5 --"wikibase:language"--> c7 end subgraph minus2["MINUS"] style minus2 stroke-width:6px,fill:pink,stroke:red; v3 --"wikibase:rank"--> c9 end bind4[/"sample(?number)"/] v6 --o bind4 bind4 --as--o v6