sparql-examples

A set of SPARQL examples that are used in different SIB resources

View the Project on GitHub sib-swiss/sparql-examples

neXtProt/NXQ_09430

Check there are no entries that do not have a gene name

Use at

PREFIX : <http://nextprot.org/rdf/>
PREFIX cv: <http://nextprot.org/rdf/terminology/>

select distinct ?entry where {
  ?entry :gene  ?gene .
  filter not exists {?gene :name ?_ }
}
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
  v2("?_")
  v3("?entry"):::projected 
  v1("?gene")
  f0[["not  "]]
  subgraph f0e0["Exists Clause"]
    e0v1 --":name"-->  e0v2
    e0v2("?_"):::projected 
    e0v1("?gene"):::projected 
  end
  f0--EXISTS--> f0e0
  f0 --> v1
  f0 --> c1
  f0 --> v2
  v1 --":name"-->  v2
  v3 --":gene"-->  v1