Summary of SQLState class codes

The first two characters of the SQLState messages in Table 27 are in bold to indicate the class code . These class codes are summarized in Table 25.

Table 25. SQLState Class Codes

Code Class
00 Unqualified successful completion
01 Warning
02 No data
07 Dynamic SQL error
08 Connection exception
09 Triggered action exception
0A Feature not supported
0F Invalid token
21 Cardinality violation
22 Data exception
23 Constraint violation
24 Invalid cursor state
25 Invalid transaction state
26 Invalid SQL statement identifier
28 Invalid authorization specification
2D Invalid transaction termination
2E Invalid connection name
34 Invalid cursor name
38 External function exception
39 External function call exception
40 Transaction rollback
42 Syntax error or access rule violation
44 With check option violation
46 Java DDL
51 Invalid application state
54 SQL or product limit exceeded
55 Object not in prerequisite state
56 Miscellaneous SQL or product error
57 Resource not available or operator intervention
58 System ErrorResource
59 DB2 Everyplace Administrator error
HY Generated by the DB2 CLI or ODBC driver
IM Generated by the ODBC driver manager

Related reference