0

After connected to AgensGraph.

I try to create node on AgensGraph.

But, there is a error on action.

kurt=# create (:v{id:1});
ERROR:  graph_path is NULL
HINT:  Use SET graph_path

How to set graph_path?

1 Answers1

0

You must create graph, before create vertex(node).

assam=# create graph new_graph;
CREATE GRAPH

After creating graph, set graph_path.

assam=# set graph_path = new_graph;
SET

Finally, You can create a vertex(node).

assam=# create (:v{id:1});
GRAPH WRITE (INSERT VERTEX 1, INSERT EDGE 0)
assam=# match (n:v) return n;
        n        
-----------------
 v[3.1]{"id": 1}
(1 row)
최현수
  • 56
  • 2