guergana.tzatchkova added a comment.

  Subqueries could be used to search for items 'not matching'
  
  We still need to find out if subqueries are supported by sparqljs 
<https://github.com/RubenVerborgh/SPARQL.js>
  
    SELECT ?item ?itemLabel ?instance WITH {
      SELECT DISTINCT ?item ?instance WHERE {
        ?item p:P281 ?statement0.
        ?statement0 (ps:P281) ?instance.
        MINUS { ?item (p:P281/ps:P281) "1350". }
      }
      LIMIT 100
    }
    AS %results WHERE {
      INCLUDE %results.
      SERVICE wikibase:label { bd:serviceParam wikibase:language 
"[AUTO_LANGUAGE]". }
    }
    LIMIT 100

TASK DETAIL
  https://phabricator.wikimedia.org/T277646

EMAIL PREFERENCES
  https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: guergana.tzatchkova
Cc: Aklapper, Lydia_Pintscher, Invadibot, maantietaja, Akuckartz, Nandana, 
Lahi, Gq86, GoranSMilovanovic, QZanden, LawExplorer, _jensen, rosalieper, 
Scott_WUaS, Wikidata-bugs, aude, Mbch331
_______________________________________________
Wikidata-bugs mailing list
Wikidata-bugs@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to