query-b7d8463302e6222afca6cbd37bd4c305
sibling (P3373)
Use at
- https://query.wikidata.org/sparql
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX ps: <http://www.wikidata.org/prop/statement/>
PREFIX p: <http://www.wikidata.org/prop/>
SELECT DISTINCT (STRAFTER(STR(?item), STR(wd:)) AS ?1) ('P3373' AS ?P3373) (STRAFTER(STR(?target), STR(wd:)) AS ?2) ('S3452' AS ?S3452) (?2 AS ?from) {
?target wdt:P3373 ?item .
MINUS { ?item p:P3373/ps:P3373 ?target } .
?item ?pred ?parent .
FILTER( ?pred IN ( wdt:P22, wdt:P25 ) ) .
?target ?pred ?parent .
} ORDER BY ?1
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v6("?1")
v7("?2"):::projected
v6("?P3373")
v8("?S3452")
v9("?from")
v4("?item"):::projected
v5("?parent")
v2("?pred")
v3("?target"):::projected
a1((" "))
list0c2(["p:direct/P25"]):::iri
list0c1(["p:direct/P22"]):::iri
list0c1 --o f0
list0c2 --o f0
f0[[" in "]]
f0 --> v2
v3 --"p:direct/P3373"--> v4
subgraph minus1["MINUS"]
style minus1 stroke-width:6px,fill:pink,stroke:red;
v4 --"p:P3373"--> a1
a1 --"p:statement/P3373"--> v3
end
v4 -->v2--> v5
v3 -->v2--> v5
bind2[/"substring-after(str(?item),str('wd:'))"/]
v4 --o bind2
bind2 --as--o v6
bind3[/"'P3373'"/]
bind3 --as--o v6
bind4[/"substring-after(str(?target),str('wd:'))"/]
v3 --o bind4
bind4 --as--o v7
bind5[/"'S3452'"/]
bind5 --as--o v8
bind6[/"?2"/]
v7 --o bind6
bind6 --as--o v9