Examples

  1. Select all Rhea reactions# Query 1 # Select all Rhea reactions (unspecified direction) # and return identifier (id), accession, boolean attributes (isChemicallyBalanced, isTransport) and chemical equation. # SELECT ?rhea ?id ?accession ?isChemicallyBalanced ?isTransport ?equation WHERE { ?rhea rdfs:subClassOf rh:Reaction . ?rhea rh:id ?id . ?rhea rh:accession ?accession . ?rhea rh:equation ?equation . ?rhea rh:isTransport ?isTransport . ?rhea rh:isChemicallyBalanced ?isChemicallyBalanced . }
  2. Select all Rhea reactions annotated with a given Pubmed ID# Query 2 # Select all Rhea reactions annotated with a given Pubmed identifier (PMID = 29867142) # SELECT ?pubmed ?rhea ?accession ?isTransport ?equation WHERE { ?rhea rdfs:subClassOf rh:Reaction . ?rhea rh:accession ?accession . ?rhea rh:citation ?pubmed . VALUES (?pubmed) { (pubmed:29867142) } ?rhea rh:isTransport ?isTransport . ?rhea rh:equation ?equation . } ORDER BY ?rhea
  3. Select the specific form of RHEA:11628.# Query 3 # Select the specific form of RHEA:11628. # This query mimics the Related reactions sections of # https://www.rhea-db.org/rhea/11628 # SELECT ?rhea ?equation ?childrenRhea ?childrenEquation WHERE { VALUES (?rhea) {(rh:11628)} ?rhea rh:equation ?equation . ?childrenRhea rdfs:subClassOf+ ?rhea . ?childrenRhea rh:equation ?childrenEquation . }
  4. Select all cross-references for a given reaction# Query 4 # Select all cross-references mapped to RHEA:21016 # # This query mimics the Cross-references section of # https://www.rhea-db.org/rhea/21016 # SELECT distinct ?rhea ?rheaDir ?xref WHERE { ?rhea rdfs:subClassOf rh:Reaction . VALUES (?rhea) {(rh:21016)} { ?rhea rdfs:seeAlso ?xref . BIND(?rhea as ?rheaDir) } UNION { ?rhea rh:directionalReaction ?directionalReaction . ?directionalReaction rdfs:seeAlso ?xref . BIND(?directionalReaction as ?rheaDir ) } UNION { ?rhea rh:bidirectionalReaction ?bidirectionalReaction . ?bidirectionalReaction rdfs:seeAlso ?xref . BIND(?bidirectionalReaction as ?rheaDir ) } }
  5. Select all Rhea reactions mapped to KEGG reactions# Query 5 # Select all Rhea reactions mapped to KEGG reactions # KEGG reactions are mapped to Rhea bidirectional reactions # Rhea web query: https://www.rhea-db.org/rhea?query=kegg:* # SELECT ?rhea ?kegg ?rheaDir WHERE { ?rhea rdfs:subClassOf rh:Reaction . ?rhea rh:bidirectionalReaction ?rheaDir . ?rheaDir rdfs:seeAlso ?kegg . FILTER (regex(str(?kegg),'kegg')) }
  6. Select all Rhea reactions mapped to MetaCyc reactions# Query 6 # Select all Rhea reactions mapped to MetaCyc reactions # MetaCyc reactions are mapped to either undirected, left-to-right, right-to-left or bidirectional reactions # Rhea web query: https://www.rhea-db.org/rhea?query=metacyc:* # SELECT distinct ?rhea ?rheaDir ?metacyc WHERE { ?rhea rdfs:subClassOf rh:Reaction . { ?rhea rdfs:seeAlso ?metacyc . FILTER CONTAINS(str(?metacyc), "METACYC") BIND(?rhea as ?rheaDir) } UNION { ?rhea rh:directionalReaction ?directionalReaction . ?directionalReaction rdfs:seeAlso ?metacyc . FILTER CONTAINS(str(?metacyc), "METACYC") BIND(?directionalReaction as ?rheaDir ) } UNION { ?rhea rh:bidirectionalReaction ?bidirectionalReaction . ?bidirectionalReaction rdfs:seeAlso ?metacyc . FILTER CONTAINS(str(?metacyc), "METACYC") BIND(?bidirectionalReaction as ?rheaDir ) } }
  7. Select all Rhea reactions mapped to Reactome reactions# Query 7 # Select all Rhea reactions mapped to Reactome reactions # MetaCyc reactions are mapped to either undirected, left-to-right or right-to-left reactions # Rhea web query: https://www.rhea-db.org/rhea?query=reactome:* # SELECT distinct ?rhea ?rheaDir ?reactome WHERE { ?rhea rdfs:subClassOf rh:Reaction . { ?rhea rdfs:seeAlso ?reactome . FILTER CONTAINS(str(?reactome), "reactome") BIND(?rhea as ?rheaDir) } UNION { ?rhea rh:directionalReaction ?directionalReaction . ?directionalReaction rdfs:seeAlso ?reactome . FILTER CONTAINS(str(?reactome), "reactome") BIND(?directionalReaction as ?rheaDir ) } }
  8. Select all Rhea reactions mapped to GO molecular function# Query 8 # Select all Rhea reactions mapped to GO molecular function # # This query corresponds to the Rhea web site query : # https://www.rhea-db.org/rhea?query=go:* # SELECT ?go ?rhea ?equation WHERE { ?rhea rdfs:subClassOf rh:Reaction . ?rhea rdfs:seeAlso ?go . FILTER CONTAINS(str(?go), "GO_") ?rhea rh:equation ?equation . }
  9. Select all Rhea reactions mapped to enzyme classification (EC numbers)# Query 9 # Select all Rhea reactions mapped to EC numbers (enzyme classification) # # This query corresponds to the Rhea web site query : # https://www.rhea-db.org/rhea?query=ec:* # SELECT ?ec ?ecNumber ?rhea ?accession ?equation WHERE { ?rhea rdfs:subClassOf rh:Reaction . ?rhea rh:accession ?accession . ?rhea rh:ec ?ec . BIND(strafter(str(?ec),str(ec:)) as ?ecNumber) ?rhea rh:isTransport ?isTransport . ?rhea rh:equation ?equation . }
  10. Select all Rhea reactions linked to an enzyme classification (sub)-class# Query 10 # Select all Rhea reactions mapped to # # This query corresponds to the Rhea web site query : # https://www.rhea-db.org/rhea?query=ec:1.* # https://www.rhea-db.org/rhea?query=ec:1.1.* # https://www.rhea-db.org/rhea?query=ec:1.1.1.* # SELECT ?ec ?ecNumber ?rhea ?accession ?equation WHERE { ?rhea rdfs:subClassOf rh:Reaction . ?rhea rh:accession ?accession . ?rhea rh:ec ?ec . BIND(strafter(str(?ec),str(ec:)) as ?ecNumber) # class (e.g EC 1.-.-.-) FILTER (regex(?ecNumber,'^1\\.')) # sub-class (e.g EC 1.1.-.-) #FILTER (regex(?ecNumber,'^1\\.1\\.')) # sub-sub-class (e.g EC 1.1.1.-) #FILTER (regex(?ecNumber,'^1\\.1\\.1\\.')) ?rhea rh:equation ?equation . }
  11. Distribution of reactions according to the first class of the enzyme classification (federated query)# Query 11 # Retrieve the count of reactions mapped to each level (main class) of the enzyme classification # # This query mimics the Filter section of the Rhea web site (Browse all reactions) # https://www.rhea-db.org/rhea?query= SELECT ?ecClass (STR(?ecName) AS ?ecClassName) (COUNT(?rhea) AS ?rheaCount) WHERE { SERVICE <https://sparql.uniprot.org/sparql> { VALUES (?ecClass) { (ec:1.-.-.-)(ec:2.-.-.-)(ec:3.-.-.-)(ec:4.-.-.-)(ec:5.-.-.-) (ec:6.-.-.-) (ec:7.-.-.-)} ?ecNumber rdfs:subClassOf ?ecClass . ?ecClass skos:prefLabel ?ecName . } ?rhea rdfs:subClassOf rh:Reaction . ?rhea rh:ec ?ecNumber . } GROUP BY ?ecClass ?ecName
  12. Select all Rhea reactions linked to enzyme sequences in UniProtKB# Query 12 # Select all Rhea reactions used to annotate enzyme sequences in UniProtKB # return the number of UniProtKB entries # Federated query using a service to UniProt SPARQL endpoint # # This query corresponds to the Rhea web site query : # https://www.rhea-db.org/rhea?query=uniprot:* # SELECT ?spCount ?rhea ?accession ?equation WHERE { SERVICE <https://sparql.uniprot.org/sparql> { SELECT ?rhea (count(?uniprot) as ?uniprotCount) { ?uniprot up:annotation/up:catalyticActivity/up:catalyzedReaction ?rhea . } GROUP BY ?rhea } ?rhea rh:accession ?accession . ?rhea rh:equation ?equation . }
  13. Select all Rhea reactions used in UniProtKB/Swiss-Prot for a given organism (NCBI taxonomy ID).# Query 13 # Select all Rhea reactions used to annotate Escherichia coli (taxid=83333) in UniProtKB/Swiss-Prot # return the number of UniProtKB entries # # Federated query using a service to UniProt SPARQL endpoint # # This query cannot be performed using the Rhea search web site SELECT ?uniprot ?mnemo ?rhea ?accession ?equation WHERE { SERVICE <https://sparql.uniprot.org/sparql> { ?uniprot up:reviewed true . ?uniprot up:mnemonic ?mnemo . ?uniprot up:organism ?taxid . VALUES (?taxid) { (taxon:83333) } ?uniprot up:annotation/up:catalyticActivity/up:catalyzedReaction ?rhea . } ?rhea rh:accession ?accession . ?rhea rh:equation ?equation . }
  14. Select all Rhea reactions that have a given ChEBI ID as reaction participant# Query 14 # Select all Rhea reactions that have CHEBI:29985 (L-glutamate) as reaction participant # # This query corresponds to the Rhea web site query : # https://www.rhea-db.org/rhea?query=chebi:29985 SELECT distinct ?chebi ?rhea ?equation WHERE { ?rhea rdfs:subClassOf rh:Reaction . ?rhea rh:equation ?equation . ?rhea rh:side/rh:contains/rh:compound ?compound . # # the ChEBI can be used either as a small molecule, the reactive part of a macromolecule or as a polymer. # ?compound (rh:chebi|(rh:reactivePart/rh:chebi)|(rh:underlyingChebi/rh:chebi)) ?chebi . VALUES (?chebi) { (CHEBI:29985) } }
  15. Select all ChEBI compounds used in Rhea as reaction participant# Query 15 # Select all ChEBI compounds used in Rhea as reaction participant # # This query can not be expressed in the Rhea web site SELECT ?chebi ?name (count(?rhea) as ?countRhea) WHERE { ?rhea rdfs:subClassOf rh:Reaction . ?rhea rh:side/rh:contains/rh:compound ?compound . # # the ChEBI can be used either as a small molecule, the reactive part of a macromolecule or as a polymer. # ?compound (rh:chebi|(rh:reactivePart/rh:chebi)|(rh:underlyingChebi/rh:chebi)) ?chebi . ?chebi up:name ?name . } GROUP BY ?chebi ?name ORDER BY DESC(?countRhea)
  16. Select all Rhea reactions that have a pair of ChEBI IDs as reaction participant and in opposite side# Query 16 # Select all Rhea reactions that have a pair of ChEBI IDs as reaction participant and in opposite side # Return Rhea reactions that have CHEBI:29985 (L-glutamate) as reaction participant in one side # and CHEBI:58359 (L-glutamine) in the other side # # This query cannot be expressed in the Rhea web site SELECT ?chebi1 ?name1 ?chebi2 ?name2 ?rhea ?equation WHERE { VALUES (?chebi1) { (CHEBI:29985) } ?chebi1 up:name ?name1 . ?rhea rh:side ?reactionSide1 . ?reactionSide1 rh:contains / rh:compound / rh:chebi ?chebi1 . VALUES (?chebi2) { (CHEBI:58359) } ?chebi2 up:name ?name2 . ?rhea rh:side ?reactionSide2 . ?reactionSide2 rh:contains / rh:compound / rh:chebi ?chebi2 . ?reactionSide1 rh:transformableTo ?reactionSide2 . ?rhea rh:equation ?equation . }
  17. Select all Rhea reactions that involve a lipid, i.e a children of CHEBI:18059 in the ChEBI hierarchy.# Query 17 # Select all Rhea reactions that involve a lipid, i.e a children of CHEBI:18059 in the ChEBI hierarchy. # # This query corresponds to the Rhea web site query : # https://www.rhea-db.org/rhea?query=chebi:18059 # SELECT distinct ?chebi ?name ?rhea ?equation WHERE { ?rhea rdfs:subClassOf rh:Reaction . ?rhea rh:equation ?equation . ?rhea rh:side/rh:contains/rh:compound ?compound . # # the ChEBI can be used either as a small molecule, the reactive part of a macromolecule or as a polymer. # { ?chebi rdfs:subClassOf* CHEBI:18059 . ?compound (rh:chebi|(rh:reactivePart/rh:chebi)|(rh:underlyingChebi/rh:chebi)) ?chebi . } UNION { ?not7_3 rdfs:subClassOf* CHEBI:18059 . ?not7_3 rdfs:subClassOf ?chebiRestriction . ?chebiRestriction a owl:Restriction . ?chebiRestriction owl:onProperty chebihash:has_major_microspecies_at_pH_7_3 . ?chebiRestriction owl:someValuesFrom ?chebi . ?compound (rh:chebi|(rh:reactivePart/rh:chebi)|(rh:underlyingChebi/rh:chebi)) ?chebi . } ?chebi up:name ?name . }

News

About

This SPARQL endpoint contains Rhea reactions data (see statistics), and a snapshot of ChEBI data matching the Rhea release. It is free to access and supports the SPARQL 1.1 Standard.

The query timeout is 45 minutes. All triples are available in the default graph. There are two named graphs: Rhea and ChEBI.

Documentation

  1. Statistics and diagrams
  2. Example queries
  3. Release data