query-30006ff6ef2971214231673cadadb101

rq turtle/ttl

list of items of a certain type with an enwiki sitelink but not a hewiki sitelink SELECT DISTINCT ?item ?itemLabel ?article1 WITH { SELECT ?item ?itemLabel ?article1 WHERE { ?article1 schema:about ?item; schema:isPartOf https://en.wikipedia.org/. } LIMIT 100000 } as %i WHERE { INCLUDE %i FILTER NOT EXISTS { ?article2 schema:about ?item; schema:isPartOf https://he.wikipedia.org/. } SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". } }

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX schema: <http://schema.org/>
PREFIX bd: <http://www.bigdata.com/rdf#>
#list of items of a certain type with an enwiki sitelink but not a hewiki sitelink
SELECT DISTINCT ?item ?itemLabel ?article1 WHERE
{
   { SELECT ?item ?itemLabel ?article1 
WHERE {
   ?article1 schema:about ?item;
   schema:isPartOf <https://en.wikipedia.org/>.
} LIMIT 100000 }  FILTER NOT EXISTS {
      ?article2 schema:about ?item;
            schema:isPartOf <https://he.wikipedia.org/>.
   }
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en". }
}

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v3("?article1"):::projected v1("?article2") v2("?item"):::projected c4([https://en.wikipedia.org/]):::iri c3([https://he.wikipedia.org/]):::iri c6(["bd:serviceParam"]):::iri c8(["#91;AUTO_LANGUAGE#93;,en"]):::literal f0[["not "]] subgraph f0e0["Exists Clause"] e0v1 --"schema:about"--> e0v2 e0v1 --"schema:isPartOf"--> e0c3 e0v1("?article2"):::projected e0v2("?item"):::projected e0c3([https://he.wikipedia.org/]):::iri end f0--EXISTS--> f0e0 f0 --> v1 f0 --> c1 f0 --> v2 f0 --> c2 f0 --> c3 v1 --"schema:about"--> v2 v1 --"schema:isPartOf"--> c3 v3 --"schema:about"--> v2 v3 --"schema:isPartOf"--> c4 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c6 --"wikibase:language"--> c8 end