SQLState mapping to Java exception classes

SQLSTATE Class or Value Description Java Exception Class
Class 00 Successful Completion SQLException
Class 01 Warning SQLException
Class 02 No Data SQLException
Class 03 SQL Statement Not Yet Complete SQLException
Class 08 Client Connection Exception SQLNonTransientConnectionException
Class 09 Triggered Action Exception SQLException
Class 0A Feature Not Supported SQLFeatureNotSupportedException
Class 0B Invalid Transaction Initiation SQLException
Class 0F Locator Exception SQLException
Class 0L Invalid Grantor SQLException
Class 0P Invalid Role Specification SQLException
Class 20 Case Not Found SQLException
Class 21 Cardinality Violation SQLException
Class 22 Data Exception SQLDataException
22V21 INVALID_EPOCH SQLNonTransientException
Class 23 Integrity Constraint Violation SQLIntegrityConstraintViolationException
Class 24 Invalid Cursor State SQLException
Class 25 Invalid Transaction State SQLTransactionRollbackException
Class 26 Invalid SQL Statement Name SQLException
Class 27 Triggered Data Change Violation SQLException
Class 28 Invalid Authorization Specification SQLInvalidAuthorizationException
Class 2B Dependent Privilege Descriptors Still Exist SQLDataException
Class 2D Invalid Transaction Termination SQLException
Class 2F SQL Routine Exception SQLException
Class 34 Invalid Cursor Name SQLException
Class 38 External Routine Exception SQLException
Class 39 External Routine Invocation Exception SQLException
Class 3B Savepoint Exception SQLException
Class 3D Invalid Catalog Name SQLException
Class 3F Invalid Schema Name SQLException
Class 40 Transaction Rollback SQLTransactionRollbackException
Class 42 Syntax Error or Access Rule Violation SQLClientSyntaxErrorException
Class 44 WITH CHECK OPTION Violation SQLException
Class 53 Insufficient Resources SQLTransientException
53300 TOO_MANY_CONNECTIONS SQLTransientConnectionException
Class 54 Program Limit Exceeded SQLNonTransientException
Class 55 Object Not In Prerequisite State SQLNonTransientException
55V03 LOCK_NOT_AVAILABLE SQLTransactionRollbackException
Class 57 Operator Intervention SQLTransientException
57V01 ADMIN_SHUTDOWN SQLNonTransientConnectionException
57V02 CRASH_SHUTDOWN SQLNonTransientConnectionException
57V03 CANNOT_CONNECT_NOW SQLNonTransientConnectionException
Class 58 System Error SQLException
Class V0 PL/vSQL errors SQLException
Class V1 Vertica-specific multi-node errors class SQLException
Class V2 Vertica-specific miscellaneous errors class SQLException
V2000 AUTH_FAILED SQLInvalidAuthorizationException
Class VC Configuration File Error SQLNonTransientException
Class VD DB Designer errors SQLNonTransientException
Class VP User procedure errors SQLNonTransientException
Class VX Internal Error SQLException