query-114618fdfc1a41e319505af38a3e45ba
Artists who died before the 19th century
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 bd: <http://www.bigdata.com/rdf#>
SELECT DISTINCT ?artist ?artistLabel ?genderLabel ?countryLabel (year(?death) as ?deathyear) #?birthyear ?flyear
WHERE {
?artist wdt:P31 wd:Q5 ; wdt:P106/wdt:P279? wd:Q1028181 .
?artist wdt:P570 ?death FILTER(year(?death)<1800).
OPTIONAL{?artist wdt:P21 ?gender}
OPTIONAL{?artist wdt:P27 ?country}
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
} ORDER BY DESC(?deathyear)
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v3("?artist"):::projected
v5("?country")
v2("?death"):::projected
v6("?deathyear")
v4("?gender")
a1((" "))
c5(["wd:Q1028181"]):::iri
c11(["bd:serviceParam"]):::iri
c3(["wd:Q5"]):::iri
c13(["#91;AUTO_LANGUAGE#93;,en"]):::literal
f0[["year-from-dateTime(?death) < '1800^^xsd:integer'"]]
f0 --> v2
v3 --"wdt:P31"--> c3
v3 --"wdt:P106"--> a1
subgraph union0[" Union "]
subgraph union0l[" "]
style union0l fill:#abf,stroke-dasharray: 3 3;
a1 --"wdt:P279"--> c5
end
subgraph union0r[" "]
style union0r fill:#abf,stroke-dasharray: 3 3;
end
union0r <== or ==> union0l
end
v3 --"wdt:P570"--> v2
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v3 -."wdt:P21".-> v4
end
subgraph optional1["(optional)"]
style optional1 fill:#bbf,stroke-dasharray: 5 5;
v3 -."wdt:P27".-> v5
end
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c11 --"wikibase:language"--> c13
end
bind1[/"year-from-dateTime(?death)"/]
v2 --o bind1
bind1 --as--o v6