query-a28793dec31f21e56a0057252446c841
TagishsimonHAVING
Use at
- https://query.wikidata.org/sparql
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX schema: <http://schema.org/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT ?item ?itemLabel ?itemDescription WHERE {
?item wdt:P106 wd:Q10833314;
wdt:P27 wd:Q31;
wdt:P27 ?citizenship.
OPTIONAL { ?item rdfs:label ?itemLabel. FILTER(LANG(?itemLabel)="fr") }
OPTIONAL { ?item schema:description ?itemDescription. FILTER(LANG(?itemDescription)="fr") }
}
GROUP BY ?item ?itemLabel ?itemDescription
HAVING(COUNT(DISTINCT ?citizenship) = 1)
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v5("?_anon_42b5416610844a34809f33a099ae9de130684")
v4("?citizenship")
v3("?item"):::projected
v1("?itemDescription"):::projected
v2("?itemLabel"):::projected
a1((" "))
c4(["wd:Q10833314"]):::iri
c6(["wd:Q31"]):::iri
f0[[" = '1^^xsd:integer'"]]
f0 --> a1
v3 --"wdt:P106"--> c4
v3 --"wdt:P27"--> c6
v3 --"wdt:P27"--> v4
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v3 -."rdfs:label".-> v2
end
subgraph optional1["(optional)"]
style optional1 fill:#bbf,stroke-dasharray: 5 5;
v3 -."schema:description".-> v1
end
bind2[/"count(?citizenship)"/]
v4 --o bind2
bind2 --as--o v5