1

I create some vertex on AgensGraph.

And, I want to remove some properties of specific vertex.

agens=# create (:v1{v1:1,v2:2,v3:3});
GRAPH WRITE (INSERT VERTEX 1, INSERT EDGE 0)
agens=# match (n:v1) return n;
                 n                  
------------------------------------
 v1[3.1]{"v1": 1, "v2": 2, "v3": 3}
(1 row)

How to remove property on AgensGraph?

korey
  • 23
  • 2

1 Answers1

0

You can use REMOVE or SET clause for removing property.

First, use REMOVE clause with property name.

agens=# match (n:v1) remove n.v3 return n;
             n             
---------------------------
 v1[3.1]{"v1": 1, "v2": 2}
(1 row)

Second option, set null to property name.

agens=# match (n:v1) set n.v2 = null return n;
        n         
------------------
 v1[3.1]{"v1": 1}
(1 row)

Thank you.

최현수
  • 56
  • 2