›Creating Uniqueness Constraints
2.2 · Video Lesson

Creating Uniqueness Constraints

A best practice is to identify a propertyA named value stored on a node or a relationship. for all nodesA vertex in a graph. In a property graph it can carry labels and properties. in the graph that make them unique. In our movie graph, these constraintsA rule the database enforces on every node or relationship with a given label or type, rejecting any write that breaks it. are:

  • Movie nodes use movieId.
  • Person nodes use tmdbId.
  • User nodes use userId.
  • Genre nodes use name.