query-4928f0bc61a217ff418647e8586e8631

rq turtle/ttl

TODO

Use at

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX ps: <http://www.wikidata.org/prop/statement/>
PREFIX p: <http://www.wikidata.org/prop/>
SELECT DISTINCT ?item
WHERE {
  ?item p:P1733 ?statement0.
  ?statement0 (ps:P1733) _:anyValueP1733_0.
  MINUS {
    ?item p:P8956 ?statement1.
    ?statement1 (ps:P8956/(wdt:P279*)) _:anyValueP8956.
  }

MINUS {
    ?item p:P1733 ?statement2.
    ?statement2 (ps:P1733) ?thing2.
  filter(?thing2 in ('7940','245300') )
  }
}

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v1("?item"):::projected v2("?statement0") v3("?statement1") v5("?statement2") v4("?thing2") a1((" ")) a3((" ")) a2((" ")) v1 --"p:P1733"--> v2 v2 --"p:statement/P1733"--> a1 subgraph minus0["MINUS"] style minus0 stroke-width:6px,fill:pink,stroke:red; v1 --"p:P8956"--> v3 v3 --"p:statement/P8956"--> a2 a2 --"p:direct/P279"--> a3 end subgraph minus1["MINUS"] style minus1 stroke-width:6px,fill:pink,stroke:red; list0c1(["7940"]):::literal list0c2(["245300"]):::literal list0c1 --o f2 list0c2 --o f2 f2[[" in "]] f2 --> v4 v1 --"p:P1733"--> v5 v5 --"p:statement/P1733"--> v4 end