About delete Node


(hong) #1

Hello,

 Is there any way to delete a given Node?
 The tour only show how to delete the edges connected to a given node, but not about the node itself.

Thanks


(Pawan Rawal) #2

Yes, you can delete a node. Deleting a node in Dgraph means that the outgoing edges/literal values attached to the node would be deleted. Any incoming edges would not be deleted.

The docs mention how to do it using RDF’s(https://docs.dgraph.io/mutations/#delete) and JSON(https://docs.dgraph.io/mutations/#deleting-edges).


(str8joy) #3

I am just wondering if you are aware that when you delete a predicate on a parent node, that causes all the other predicates to not show until a new one is created.
for example given:
<1> <2>
<1> <3>
<1> <4>

delete{
<1> <3> .
}

then!
<1> <2>
<1> <4>
no longer recongized


(Manish R Jain) #4

Replied in another thread.


(system) #5

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.