query-e93069309ed289a7217661d54a488fc5

rq turtle/ttl

TODO

Use at

PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
SELECT ?item
WHERE
{
  VALUES ?name { wd:Q12308941 wd:Q202444 }
  VALUES ?lang { wd:Q36510 wd:Q9129 wd:Q245899 }
  ?item wdt:P31 ?name .
  ?item wdt:P407 ?lang .
  FILTER EXISTS
  {
    ?item wdt:P407 ?other_lang .
    FILTER (?other_lang NOT IN( wd:Q36510, wd:Q9129, wd:Q245899 ) )
  }
}

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v2("?item"):::projected v4("?lang") v3("?name") v1("?other_lang") f0[[" "]] subgraph f0e0["Exists Clause"] e0f0[["?other_lang != 'wd:Q36510'?other_lang != 'wd:Q9129'?other_lang != 'wd:Q245899'"]] e0f0 --> e0v1 e0v2 --"wdt:P407"--> e0v1 e0v2("?item"):::projected e0v1("?other_lang"):::projected end f0--EXISTS--> f0e0 f0 --> v1 f0 --> v2 f0 --> c4 f1[["?other_lang != 'wd:Q36510'?other_lang != 'wd:Q9129'?other_lang != 'wd:Q245899'"]] f1 --> v1 v2 --"wdt:P407"--> v1 bind2[/VALUES ?name/] bind2-->v3 bind20(["wd:Q12308941"]) bind20 --> bind2 bind21(["wd:Q202444"]) bind21 --> bind2 bind3[/VALUES ?lang/] bind3-->v4 bind30(["wd:Q36510"]) bind30 --> bind3 bind31(["wd:Q9129"]) bind31 --> bind3 bind32(["wd:Q245899"]) bind32 --> bind3 v2 --"wdt:P31"--> v3 v2 --"wdt:P407"--> v4