query-6264bd527a9c43f673a18769bab08bb8
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 schema: <http://schema.org/>
PREFIX psv: <http://www.wikidata.org/prop/statement/value/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?item ?itemLabel ?SL ?sl_article ?birth ?precision where
{ {select ?item ?itemLabel ?SL ?sl_article ?precision (count(?birth) as ?count) where
{
?item wdt:P31 wd:Q5.
?SL schema:about ?item; # item has a sitelink
schema:isPartOf <https://sl.wikisource.org/>; # the sitelink points to sl.wikisource
schema:name ?sl_article. # and has an article name
?item p:P569/psv:P569 [wikibase:timePrecision ?precision; wikibase:timeValue ?birth]. #has a DoB with a stated precision
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" } . #this bit gets labels for Qid values
} group by ?item ?itemLabel ?SL ?sl_article ?precision } filter(?count>1)
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v3("?SL"):::projected
v6("?birth"):::projected
v7("?count")
v2("?item"):::projected
v5("?precision"):::projected
v4("?sl_article"):::projected
a2((" "))
a1((" "))
c6([https://sl.wikisource.org/]):::iri
c13(["bd:serviceParam"]):::iri
c3(["wd:Q5"]):::iri
c15(["#91;AUTO_LANGUAGE#93;,en"]):::literal
f0[["?count > '1^^xsd:integer'"]]
f0 --> v7
v2 --"p:direct/P31"--> c3
v3 --"schema:about"--> v2
v3 --"schema:isPartOf"--> c6
v3 --"schema:name"--> v4
a1 --"wikibase:timePrecision"--> v5
a1 --"wikibase:timeValue"--> v6
v2 --"p:P569"--> a2
a2 --"p:statement/value/P569"--> a1
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c13 --"wikibase:language"--> c15
end
bind2[/"count(?birth)"/]
v6 --o bind2
bind2 --as--o v7