background image
<< ELIMINATE_DUPLICATES | Class 07 - Dynamic SQL Error >>

Derby exception messages and SQL states

<< ELIMINATE_DUPLICATES | Class 07 - Dynamic SQL Error >>
Derby Reference Manual
258
Derby exception messages and SQL states
The JDBC driver returns SQLExceptions for all errors from Derby. If the exception
originated in a user type but is not itself an SQLException, it is wrapped in an
SQLException. Derby-specific SQLExceptions use SQLState class codes starting with X.
Standard SQLState values are returned for exceptions where appropriate.
Unimplemented aspects of the JDBC driver return a SQLException with a SQLState
starting with
0A
. If your application runs on JDK 1.6 or higher, then the exception class
is java.sql.SQLFeatureNotSupportedException. These unimplemented parts are for
features not supported by Derby.
Derby supplies values for the message and SQLState fields. In addition, Derby
sometimes returns multiple SQLExceptions using the nextException chain. The first
exception is always the most severe exception, with SQL-92 Standard exceptions
preceding those that are specific to Derby.
For information on processing SQLExceptions, see the Derby Developer's Guide.
SQL error messages and exceptions
The following tables list SQLStates for exceptions. Exceptions that begin with an X are
specific to Derby.
Table 68.
Class 01: Warning
SQLSTATE
Message Text
01001
An attempt to update or delete an already deleted row was made: No row
was updated or deleted.
01003
Null values were eliminated from the argument of a column function.
01006
Privilege not revoked from user <authorizationID>.
01007
Role <authorizationID> not revoked from authentication id <authorizationID>.
01008
WITH ADMIN OPTION of role <authorizationID> not revoked from
authentication id <authorizationID>.
01009
Generated column <columnName> dropped from table <tableName>.
0100E
XX Attempt to return too many result sets.
01500
The constraint <constraintName> on table <tableName> has been dropped.
01501
The view <viewName> has been dropped.
01502
The trigger <triggerName> on table <tableName> has been dropped.
01503
The column <columnName> on table <tableName> has been modified by
adding a not null constraint.
01504
The new index is a duplicate of an existing index: <indexName>.
01505
The value <valueName> may be truncated.
01522
The newly defined synonym '<synonymName>' resolved to the object
'<objectName>' which is currently undefined.
01J01
Database '<databaseName>' not created, connection made to existing
database instead.