query-291db9b788df3f8be96c5e1b77e76deb
Improve descriptions
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 ?item ?itemDescription (GROUP_CONCAT(year(?dob)) as ?dob_y) (GROUP_CONCAT(year(?dod)) as ?dod_y) (COUNT(?item) as ?nr)
WHERE
{
?item wdt:P39 wd:Q18510612 .
?item wdt:P569 ?dob .
?item wdt:P570 ?dod .
SERVICE wikibase:label { bd:serviceParam wikibase:language "en". }
}
GROUP BY ?item ?itemDescription
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v2("?dob"):::projected
v4("?dob_y")
v3("?dod"):::projected
v5("?dod_y")
v1("?item"):::projected
v6("?nr")
c6(["bd:serviceParam"]):::iri
c8(["en"]):::literal
c2(["wd:Q18510612"]):::iri
v1 --"wdt:P39"--> c2
v1 --"wdt:P569"--> v2
v1 --"wdt:P570"--> v3
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c6 --"wikibase:language"--> c8
end
bind3[/"year-from-dateTime(?dob)"/]
v2 --o bind3
bind3 --as--o v4
bind4[/"year-from-dateTime(?dod)"/]
v3 --o bind4
bind4 --as--o v5
bind5[/"count(?item)"/]
v1 --o bind5
bind5 --as--o v6