sparql-examples

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

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

8

rq turtle/ttl

Find in any organsim under Gammaproteobacteria all genes containing word "protease", case-insensitive, anywhere in description

Use at

PREFIX up: <http://purl.uniprot.org/core/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
PREFIX : <http://purl.orthodb.org/>

SELECT *
WHERE {
    ?tx rdfs:subClassOf+/up:scientificName "Gammaproteobacteria".
    ?gene a :Gene; up:organism/a ?tx; :description ?description.
    FILTER(contains (lcase(?description), "protease" ))
}
rdfs:subClassOf
up:scientificName
a
up:organism
a
:description
?description
?gene
?tx
:Gene
Gammaproteobacteria
contains(lower-case(?description),'protease')