›Error handling
3.3 · Lesson
Error handling
When working with Neo4j, you may encounter various database errors that need to be handled gracefully in your application.
The driver throws exceptions that inherit from Neo4jException for all database-related errors.
Exceptions related to the driver and its connection are subclasses of ServiceUnavailableException.
ClientException—Raised when the iFull definition for Cypher (opens in a new tab)Neo4j's implementation of GQL, the ISO standard query language for graph databases. It is declarative: you describe the pattern to find, and the database decides how to find it. syntax is invalid or a iFull definition for constraint (opens in a new tab)A rule the database enforces on every node or relationship with a given label or type, rejecting any write that breaks it. is violatedAuthenticationException—Raised when authentication failsServiceUnavailableException—Raised when the database is not accessibleTransientException—Raised for temporary failures that may succeed on retry
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