-
Notifications
You must be signed in to change notification settings - Fork 47
Cypher language extension
SciGraph has some extensions to the Cypher query language.
In a Cypher query, instead of using the full IRI to describe a node or a relationship type, curies can be used as a shorthand. To do the curie to iri expansion, SciGraph uses the mapping defined in the yaml configuration file.
For example MATCH (n)-[:RO:0002200]->(m)
becomes MATCH (n)-[:`http://purl.obolibrary.org/obo/RO_0002200`]->(m)
.
When traversing with a specific relationship type, one would be likely interested in the sub and equivalent properties of this relationship type. Instead of enumerating all those relationship types manually, SciGraph provides the short hand !
to add those additional relationship types.
For example MATCH (n)-[:RO:0002200!]->(m)
becomes MATCH (n)-[:`http://purl.obolibrary.org/obo/GENO_0000743`|`http://purl.obolibrary.org/obo/GENO_0000740`|`http://purl.obolibrary.org/obo/RO_0002452`|`http://purl.obolibrary.org/obo/RO_0002200`]->(m) RETURN n
.