DEV Community

Muhammad Muneeb Ur Rehman
Muhammad Muneeb Ur Rehman

Posted on

Create & Delete Graph in AGE

To create Graphs in AGE firstly we need to have a database in PostgreSQL.
Firstly, run the PostgreSQL server.

Start Server
pg_ctl -D usr/local/pgsql/data -l logfile start

Databases List
psql -l

Select Database
psql databaseName

If you have no database created. You can create one by:
CREATE DATABASE databasename

For First time create extension on database.
CREATE EXTENSION age;

Load AGE
LOAD 'age';

Set the search path
SET search_path = ag_catalog, "$user", public;

Create a Graph
create_graph(graph_name);

Delete a Graph
drop_graph(graph_name, cascade);

For more details visit: https://age.apache.org/overview/

AGE Github Link: https://github.com/apache/age

AGE Viewer Github Link: https://github.com/apache/age-viewer

Top comments (0)