NeptuneData / Client / execute_open_cypher_query

execute_open_cypher_query#

NeptuneData.Client.execute_open_cypher_query(**kwargs)#

Executes an openCypher query. See Accessing the Neptune Graph with openCypher for more information.

Neptune supports building graph applications using openCypher, which is currently one of the most popular query languages among developers working with graph databases. Developers, business analysts, and data scientists like openCypher’s declarative, SQL-inspired syntax because it provides a familiar structure in which to querying property graphs.

The openCypher language was originally developed by Neo4j, then open-sourced in 2015 and contributed to the openCypher project under an Apache 2 open-source license.

Note that when invoking this operation in a Neptune cluster that has IAM authentication enabled, the IAM user or role making the request must have a policy attached that allows one of the following IAM actions in that cluster, depending on the query:

Note also that the neptune-db:QueryLanguage:OpenCypher IAM condition key can be used in the policy document to restrict the use of openCypher queries (see Condition keys available in Neptune IAM data-access policy statements).

See also: AWS API Documentation

Request Syntax

response = client.execute_open_cypher_query(
    openCypherQuery='string',
    parameters='string'
)
Parameters:
  • openCypherQuery (string) –

    [REQUIRED]

    The openCypher query string to be executed.

  • parameters (string) – The openCypher query parameters for query execution. See Examples of openCypher parameterized queries for more information.

Return type:

dict

Returns:

Response Syntax

{
    'results': {...}|[...]|123|123.4|'string'|True|None
}

Response Structure

  • (dict) –

    • results (document) –

      The openCypherquery results.

Exceptions