query-ce1aadad53fd8f4aaed82d460768b2a3

rq turtle/ttl

TODO

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX skos: <http://www.w3.org/2004/02/skos/core#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT DISTINCT ?ent2 ?wdtProperty2 ?val ?valLabel 


WHERE { 
   { SELECT * WHERE { VALUES ?label2 { rdfs:label skos:altLabel } ?wdPopulation2 ?label2 "religion"@en . ?wdPopulation2 wikibase:directClaim ?wdtProperty2 . } }
   { SELECT * WHERE { VALUES ?labelB2 { rdfs:label skos:altLabel } ?ent2 ?labelB2 "Buddhism"@en . } }

  VALUES ?label1 { rdfs:label skos:altLabel } ?val wdt:P31 [ ?label1 'people'@en ].
  ?val ?wdtProperty2 ?ent2 . 

  OPTIONAL { ?val rdfs:label ?valLabel FILTER(lang(?valLabel) = "en") } 

} LIMIT 10

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v6("?ent2"):::projected v7("?label1") v2("?label2") v5("?labelB2") v8("?val"):::projected v1("?valLabel"):::projected v3("?wdPopulation2") v4("?wdtProperty2"):::projected a1((" ")) c4([sBuddhism^^<http://www.w3.org/1999/02/22-rdf-syntax-ns#langString>"]):::literal c5([speople^^<http://www.w3.org/1999/02/22-rdf-syntax-ns#langString>"]):::literal c2([sreligion^^<http://www.w3.org/1999/02/22-rdf-syntax-ns#langString>"]):::literal bind0[/VALUES ?label2/] bind0-->v2 bind00(["rdfs:label"]) bind00 --> bind0 bind01(["skos:altLabel"]) bind01 --> bind0 v3 -->v2--> c2 v3 --"wikibase:directClaim"--> v4 bind1[/VALUES ?labelB2/] bind1-->v5 bind10(["rdfs:label"]) bind10 --> bind1 bind11(["skos:altLabel"]) bind11 --> bind1 v6 -->v5--> c4 bind2[/VALUES ?label1/] bind2-->v7 bind20(["rdfs:label"]) bind20 --> bind2 bind21(["skos:altLabel"]) bind21 --> bind2 a1 -->v7--> c5 v8 --"wdt:P31"--> a1 v8 -->v4--> v6 subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v8 -."rdfs:label".-> v1 end