query-e17a00f28aa16381f2911b253a3a20eb
Pokémon not having egg group. I created this query but I'm not sure it is correct: (Q26037540)Egg group I don't know what I'm doing :D I'd like to create a query that lists all Pokémon that doesn't have an item about its
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 pq: <http://www.wikidata.org/prop/qualifier/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?no ?item ?itemLabel
WHERE
{
?item wdt:P31 ?type.
?type wdt:P279 wd:Q3966183.
?item p:P1112 ?no .
?no pq:P642 wd:Q20005020.
MINUS {
?item wdt:P31 ?type.
?type wdt:P279 wd:Q3966183.
?item wdt:P361 ?egg.
?egg wdt:P279 wd:Q26037540.
}
SERVICE wikibase:label { bd:serviceParam wikibase:language "it" }
}
ORDER BY ?no
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v4("?egg")
v2("?item"):::projected
v1("?no"):::projected
v3("?type")
c3(["wd:Q3966183"]):::iri
c10(["bd:serviceParam"]):::iri
c8(["wd:Q26037540"]):::iri
c6(["wd:Q20005020"]):::iri
c12(["it"]):::literal
v2 --"p:direct/P31"--> v3
v3 --"p:direct/P279"--> c3
v2 --"p:P1112"--> v1
v1 --"p:qualifier/P642"--> c6
subgraph minus0["MINUS"]
style minus0 stroke-width:6px,fill:pink,stroke:red;
v2 --"p:direct/P31"--> v3
v3 --"p:direct/P279"--> c3
v2 --"p:direct/P361"--> v4
v4 --"p:direct/P279"--> c8
end
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c10 --"wikibase:language"--> c12
end