DB2 Error codes and Handling

DB2 NULL Statement

Advertisements


Error code can be handled in the program by using SQLCODE validation after each query executed.

Most of very frequent error codes described below.

The SQLCODE is equal to 000, the query executed successfully.

If the SQLCODE is positive, Then the Query executed with Warning.

If the SQLCODE is negative, then the Query returns errors.

Note:
+ SQLCODE ------ will return the SQL return code for the query provided but not for the condition provided.

All 900 series SQLCODE are Authorization and DEADLOCK errors.

DB2 NULL Statement

Advertisements