query-d54c0b70862cdaa4c443632fbc565705
TODO
Use at
- https://query.wikidata.org/sparql
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 WHERE {
?item p:P166 ?s .
?s ps:P166 wd:Q3432243 .
OPTIONAL { ?s pq:P585 ?time . BIND(YEAR(?time) AS ?year) }
SERVICE wikibase:label { bd:serviceParam wikibase:language 'en' }
} ORDER BY ASC(?year)
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v2("?item"):::projected
v3("?s")
v4("?time")
v5("?year"):::projected
c3(["wd:Q3432243"]):::iri
c6(["bd:serviceParam"]):::iri
c8(["en"]):::literal
v2 --"p:P166"--> v3
v3 --"p:statement/P166"--> c3
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v3 -."p:qualifier/P585".-> v4
bind0[/"year-from-dateTime(?time)"/]
v4 --o bind0
bind0 --as--o v5
end
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c6 --"wikibase:language"--> c8
end