query-0dc34a7efd3f64b205610ec7726476e7
BBLd - Baltisches Biographisches Lexikon digital - year of birth, year of death from P2580. The "-None" in the ID is important, because if an ID only ends in -YYYY it could be yob or yod. Here for yob : (P2580)P2580 ~660 year of birth/~670 year of death can be harvested from
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 ?itemLabel ?bbld
{
?item wdt:P31 wd:Q5.
?item wdt:P2580 ?bbld .
MINUS{?item wdt:P569 [] .}
#MINUS{?item wdt:P570 [] .}
FILTER (REGEX(STR(?bbld), "-[0-9]{4}-([0-9]{4}|None)$"))
#FILTER (REGEX(STR(?bbld), "-([0-9]{4}|None)-[0-9]{4}$"))
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v1("?bbld"):::projected
v2("?item"):::projected
a1((" "))
c7(["bd:serviceParam"]):::iri
c3(["wd:Q5"]):::iri
c9(["#91;AUTO_LANGUAGE#93;,en"]):::literal
f0[["regex(str(?bbld),'-#91;0-9#93;{4}-(#91;0-9#93;{4}|None)$')"]]
f0 --> v1
v2 --"wdt:P31"--> c3
v2 --"wdt:P2580"--> v1
subgraph minus1["MINUS"]
style minus1 stroke-width:6px,fill:pink,stroke:red;
v2 --"wdt:P569"--> a1
end
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c7 --"wikibase:language"--> c9
end