Querying a Neptune Graph
Neptune supports the following graph query languages to access a graph:
-
Gremlin
, defined by Apache TinkerPop for creating and querying property graphs. A query in Gremlin is a traversal made up of discrete steps, each of which follows an edge to a node.
See Accessing a Neptune graph with Gremlin to learn about using Gremlin in Neptune, and Gremlin standards compliance in Amazon Neptune to find specific details about the Neptune implementation of Gremlin.
-
openCypher is a declarative query language for property graphs that was originally developed by Neo4j, then open-sourced in 2015, and contributed to the openCypher
project under an Apache 2 open-source license. Its syntax is documented in the openCypher spec . -
SPARQL
is a declarative language based on graph pattern-matching, for querying RDF data. It is supported by the World Wide Web Consortium . See Accessing the Neptune graph with SPARQL to learn about using SPARQL in Neptune, and SPARQL standards compliance in Amazon Neptune to find specific details about the Neptune implementation of SPARQL.
Note
Both Gremlin and openCypher can be used to query any property-graph data stored in Neptune, regardless of how it was loaded.