10.4 Loading a Subgraph from a PGQL Property Graph
You can create a subgraph from a PGQL property graph and load it into memory in the graph server (PGX).
Instead of loading a full graph into memory, you can load a subgraph. This would consume less memory.
The following sections explain in detail on loading and expanding of subgraphs:
- PGQL Based Subgraph Loading
You can use thePgViewSubgraphReader#fromPgView
API to create an in-memory subgraph from a PGQL property graph using a set of PGQL queries. - Prepared PGQL Queries
You can also use prepared queries when loading a subgraph from a PGQL property graph. - Providing Database Connection Credentials
You can specify the database connection credentials with thePgViewSubgraphReader#fromPgView
API instead of using the default credentials of the current user. - Dynamically Expanding a Subgraph
You can expand an in-memory subgraph by loading another subgraph into memory and merging it with the current in-memory subgraph.