Constraints in Neo4j
A constraintA rule the database enforces on every node or relationship with a given label or type, rejecting any write that breaks it. is implemented internally as an index. It is used to constrain what is added to the graph.
You can define different types of constraint that apply to nodesA vertex in a graph. In a property graph it can carry labels and properties. with a specific labelA tag on a node that groups it with other nodes of the same kind. A node can carry more than one. or relationshipsA named, directed connection between two nodes. Every relationship has a type, a start node and an end node. of a type, including:
Join GraphAcademy to keep learning
Create your account to unlock 80+ hours of hands-on Neo4j courses, track your progress, and earn a certificate when you complete the course.
Sign in or register