Database Reference
In-Depth Information
In Neo4j, you could model the same scenario by representing users and groups as
nodes
,
and group membership as a
relationship
between nodes (
figure 2.2
)
.
Figure 2.2. A person belongs to a group.
Here you can see that
nodes
are, roughly, the entities of the data model (in RDBMS terms)
of a graph database, and
relationships
are, unsurprisingly, the relationships or connections
between nodes. The plain English sentence that corresponds to this diagram is “A person
belongs to a group.”
Let's see how that looks with several people, and several groups (
figure 2.3
)
.