query-e1d9aab7a1aaaa5a9dc095fd3acbaa70
Person with missing profession Propertiesinstance of (P31)country of citizenship (P27)occupation (P106)
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 bd: <http://www.bigdata.com/rdf#>
SELECT ?item ?itemLabel ?itemDescription WHERE {
?item wdt:P31 wd:Q5.
?item wdt:P27 wd:Q31.
SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE]" }
FILTER(EXISTS {
?item schema:description ?itemdesc.
FILTER(LANG(?itemdesc) = "[AUTO_LANGUAGE]")
})
MINUS { ?item wdt:P106 [] }
}
ORDER BY ?itemLabel
Query found at
- https://www.wikidata.org/wiki/User:Geertivp/training/Wikidata_Query/Person_with_missing_profession
- https://www.wikidata.org/wiki/User:Vislupus
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v3("?item"):::projected
v1("?itemLabel"):::projected
v2("?itemdesc")
a1((" "))
c8(["bd:serviceParam"]):::iri
c1(["#91;AUTO_LANGUAGE#93;"]):::literal
c4(["wd:Q5"]):::iri
c6(["wd:Q31"]):::iri
f0[[" "]]
subgraph f0e0["Exists Clause"]
e0f0[["?itemdesc = '#91;AUTO_LANGUAGE#93;'"]]
e0f0 --> e0v1
e0v2 --"schema:description"--> e0v1
e0v2("?item"):::projected
e0v1("?itemdesc"):::projected
end
f0--EXISTS--> f0e0
f0 --> v2
f0 --> v3
f0 --> c2
f1[["?itemdesc = '#91;AUTO_LANGUAGE#93;'"]]
f1 --> v2
v3 --"schema:description"--> v2
v3 --"wdt:P31"--> c4
v3 --"wdt:P27"--> c6
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c8 --"wikibase:language"--> c1
end
subgraph minus2["MINUS"]
style minus2 stroke-width:6px,fill:pink,stroke:red;
v3 --"wdt:P106"--> a1
end