Listing of SQLSTATE class codes

This table provides a list of general SQLSTATE classes. Each class links to a list of the more specific SQLSTATE codes that comprise that class.

Class code Meaning Subcodes
00 Unqualified Successful Completion Table 1
01 Warning Table 2
02 No Data Table 3
07 Dynamic SQL Error Table 4
08 Connection Exception Table 5
09 Triggered Action Exception Table 6
0A Feature Not Supported Table 7
0E Invalid Schema Name List Specification Table 8
0F Invalid Token Table 9
0K Resignal When Handler Not Active Table 10
Start of change0NEnd of change Start of changeSQL/XML Mapping ErrorEnd of change Start of changeTable 11End of change
0W Prohibited Statement Encountered During Trigger Table 12
0Z Diagnostics Exception Table 13
20 Case Not Found for Case Statement Table 14
21 Cardinality Violation Table 15
22 Data Exception Table 16
23 Constraint Violation Table 17
24 Invalid Cursor State Table 18
25 Invalid Transaction State Table 19
26 Invalid SQL Statement Identifier Table 20
27 Triggered Data Change Violation Table 21
28 Invalid Authorization Specification Table 22
2D Invalid Transaction Termination Table 23
2E Invalid Connection Name Table 24
2F SQL Function Exception Table 25
33 Invalid SQL Descriptor Name Table 26
34 Invalid Cursor Name Table 27
35 Invalid Condition Number Table 28
36 Cursor Sensitivity Exception Table 29
38 External Function Exception Table 30
39 External Function Call Exception Table 31
3B Invalid SQL Descriptor Name Table 32
3C Ambiguous Cursor Name Table 33
42 Syntax Error or Access Rule Violation Table 34
44 WITH CHECK OPTION Violation Table 35
46 Java™ Errors Table 36
51 Invalid Application State Table 37
53 Invalid Operand or Inconsistent Specification Table 38
54 SQL or Product Limit Exceeded Table 39
55 Object Not in Prerequisite State Table 40
56 Miscellaneous SQL or Product Error Table 41
57 Resource Not Available or Operator Intervention Table 42
58 System Error Table 43