DB2 Error Codes / DB2 SQL Codes :

 

0  – Successful execution.

 

+100  – End of the data.

 

-203  – Reference to Column name is ambiguous. The column name is specified at more than one place.

 

-204  – Undefined table name

 

-205  –  Column name is not defined in table.

 

-216 – The number of columns in select statement is not equal to number of host variables listed.

 

-305 – Null value cannot be assigned to host variable. Null indicator not specified.

 

-311  –  The length of the VARCHAR field is not set correctly.

-501  –  Cursor not open on FETCH or CLOSE.

 

-502  –  Opening cursor that is already open.

 

-503  –  Updating column needs to be specified.

 

-504  –  Cursor is not declared.

 

-803  –  Duplicate record while inserting. Same Primary Key values for two records.

 

 -805  –  DBRM or package not found in plan.

 

 -811  –  The select statement retrieved more than one row. Use Cursor or  “FETCH FIRST 1 ROW  

             ONLY” to resolve the error.

 

 -818  –  Plan and program: timestamp mismatch.

 

 -904  –  Unavailable resource.

 

 -911  –  ROLLBACK occurred due to DEADLOCK.

 

 -913  –  DEADLOCK. No ROLLBACK is done.

 

 -922  –  AUTHORIZATION failed.

 

 -927  –  Timeout.