query-cbd4918e51806f7732cb366ee17d1d20

rq turtle/ttl

Miraclepine

Use at

PREFIX xsd: <http://www.w3.org/2001/XMLSchema#>
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 ?dob ?oxford_college ?oxford_collegeLabel
WHERE
{
  { ?item wdt:P69 wd:Q34433 . }
  UNION
  {
    ?item wdt:P69 ?oxford_college .
    ?oxford_college wdt:P31 wd:Q2581649 .
  }
  ?item wdt:P31 wd:Q5 .
  ?item wdt:P569 ?dob . 
  FILTER("1685-00-00T00:00:00Z"^^xsd:dateTime <= ?dob && ?dob < "1868-00-00T00:00:00Z"^^xsd:dateTime)
  FILTER NOT EXISTS { ?item wdt:P1343 wd:Q19036877 }
  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; v2("?dob"):::projected v1("?item"):::projected v3("?oxford_college"):::projected c2(["wd:Q19036877"]):::iri c12(["bd:serviceParam"]):::iri c9(["wd:Q5"]):::iri c14(["#91;AUTO_LANGUAGE#93;,en"]):::literal c6(["wd:Q34433"]):::iri c8(["wd:Q2581649"]):::iri f0[["not "]] subgraph f0e0["Exists Clause"] e0v1 --"wdt:P1343"--> e0c2 e0v1("?item"):::projected e0c2(["wd:Q19036877"]):::iri end f0--EXISTS--> f0e0 f0 --> v1 f0 --> c1 f0 --> c2 v1 --"wdt:P1343"--> c2 f1[["'1685-00-00T00:00:00Z^^xsd:dateTime' <= ?dob?dob < '1868-00-00T00:00:00Z^^xsd:dateTime'"]] f1 --> v2 subgraph union0[" Union "] subgraph union0l[" "] style union0l fill:#abf,stroke-dasharray: 3 3; v1 --"wdt:P69"--> v3 v3 --"wdt:P31"--> c8 end subgraph union0r[" "] style union0r fill:#abf,stroke-dasharray: 3 3; v1 --"wdt:P69"--> c6 end union0r <== or ==> union0l end v1 --"wdt:P31"--> c9 v1 --"wdt:P569"--> v2 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c12 --"wikibase:language"--> c14 end