Edges, Identifiers, Handles
A graph data model always consists of at least two collections: the relations between the nodes in the graphs are stored in an “edges collection”, the nodes in the graph are stored in documents in regular collections.
Edges in ArangoDB are special documents. In addition to the system
_rev, they have the attributes
which contain document handles, namely the start-point and the end-point of the edge.
- The “edge” collection stores the information that a company’s reception is sub-unit to the services unit and the services unit is sub-unit to the
CEO. You would express this relationship with the
- The “normal” collection stores all the properties about the reception, e.g. that 20 people are working there and the room number etc
_fromis the document handle of the linked vertex (incoming relation)
_tois the document handle of the linked vertex (outgoing relation)
Edge collections are special collections that store edge documents. Edge documents are connection documents that reference other documents. The type of a collection must be specified when a collection is created and cannot be changed afterwards.
To change edge endpoints you can simply update the
like any other document attribute.
Working with Edges
Edges are normal documents
that always contain a
_from and a