6.7.6 Java APIs for Executing UPDATE Queries
The UPDATE queries make changes to existing graphs using
the INSERT, UPDATE, and
DELETE operations as detailed in the section
Graph Modification of the PGQL 1.3 specification.
Note that INSERT allows you to insert new vertices and edges into a
graph, UPDATE allows you to update existing
vertices and edges by setting their properties to new values,
and DELETE allows you to delete vertices and
edges from a graph.
- Updatability of Graphs Through PGQL
Graph data that is loaded from the Oracle RDBMS or from CSV files into the PGX is not updatable through PGQL right away. - Executing UPDATE Queries against a Graph in the in-memory Graph Server (PGX)
To executeUPDATEqueries against a graph, use thePgxGraph.executePgql(String query)method. - Executing UPDATE Queries Against a PGX Session
For now, there is no support for executingUPDATEqueries against aPgxSessionand therefore, updates always have to be executed against a PgxGraph. To obtain a graph from a session, use thePgxSession.getGraph(String graphName)method. - Altering the Underlying Schema of a Graph
TheINSERToperations can only insert vertices and edges with known labels and properties. Similarly,UPDATEoperations can only set values of known properties. Thus, new data must always conform to the existing schema of the graph.