query-189639fb03b0f306dcc2b6b98c2a5fb9
TODO
Use at
- https://query.wikidata.org/sparql
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 prov: <http://www.w3.org/ns/prov#>
PREFIX pr: <http://www.wikidata.org/prop/reference/>
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(?when) as ?year) ?winnerLabel ?score ?ref_url ?retrieved
WHERE
{
?item wdt:P31 wd:Q57776091. # the item is an instance of a Sweet Adelines International chorus competition
?item wdt:P585 ?when. # it has a when statement
?item p:P1346 [ps:P1346 ?winner ; pq:P1351 ?score; prov:wasDerivedFrom [pr:P854 ?ref_url; pr:P813 ?retrieved] ] .
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
} order by desc(?year)
Query found at
- https://www.wikidata.org/wiki/User:Tagishsimon/WDQS
- https://www.wikidata.org/wiki/User_talk:Tagishsimon
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v2("?item"):::projected
v6("?ref_url"):::projected
v7("?retrieved"):::projected
v5("?score"):::projected
v3("?when"):::projected
v4("?winner")
v8("?year")
a1((" "))
a2((" "))
c2(["wd:Q57776091"]):::iri
c11(["bd:serviceParam"]):::iri
c13(["#91;AUTO_LANGUAGE#93;,en"]):::literal
v2 --"p:direct/P31"--> c2
v2 --"p:direct/P585"--> v3
a1 --"p:statement/P1346"--> v4
a1 --"p:qualifier/P1351"--> v5
a2 --"p:reference/P854"--> v6
a2 --"p:reference/P813"--> v7
a1 --"prov:wasDerivedFrom"--> a2
v2 --"p:P1346"--> a1
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c11 --"wikibase:language"--> c13
end
bind0[/"year-from-dateTime(?when)"/]
v3 --o bind0
bind0 --as--o v8