Cause: The processing of a column function or arithmetic expression resulted in division by zero.
The statement cannot be processed. For the INSERT, UPDATE, or DELETE statements, no inserts or updates are performed.
Action: Examine the SQL statement to determine the cause of the problem. If the problem is data dependent, it is necessary to examine the data processed when the error occurred. Refer to the SQL Reference to see the valid ranges for the data types.
DataJoiner users: examine the SQL statement to determine the cause of the problem. If the problem is data dependent, examine the data being processed at the data sources when the error occurred.
sqlcode: -801
sqlstate: 22012
Cause: The processing of a column function or arithmetic expression has resulted in an arithmetic overflow.
The statement cannot be processed. For the INSERT, UPDATE, or DELETE statements, no inserts or updates are performed.
Action: Examine the SQL statement to determine the cause of the problem. If the problem is data dependent, it is necessary to examine the data processed when the error occurred. Refer to the SQL Reference to see the valid ranges for the data types.
DataJoiner users: examine the SQL statement to determine the cause of the problem. If the problem is data dependent, examine the data being processed at the data sources when the error occurred. Refer to the corresponding SQL Reference for the data source to determine the valid ranges for the data types.
sqlcode: -802
sqlstate: 22003
INSERT statement, UPDATE statement, or foreign key update caused by a DELETE statement
are not valid because they would produce duplicate rows for a table with a
primary key, unique constraint, or
unique index.
Cause: The INSERT or UPDATE object table is constrained by one or more UNIQUE indexes to have unique values in certain columns or groups of columns.
Alternatively, a DELETE statement on a parent table caused the update of a foreign key in a dependent table that is constrained by one or more UNIQUE indexes to have unique values in certain columns or groups of columns. The unique index may exist to support a primary key or unique constraint defined on the table.
Completing the requested insert or update results in duplicates of the column values.
Alternatively, if a view is the object of the INSERT or UPDATE statement, it is the table on which the view is defined that is constrained.
The statement cannot be processed. The table remains unchanged.
Action: Examine the definitions for all UNIQUE indexes defined on the object table to determine the uniqueness constraints those indexes impose.
For an UPDATE statement, ensure that the specified operation is not itself inconsistent with those uniqueness constraints. If this does not show the error, examine the object table content to determine the cause of the problem.
For an INSERT statement, examine the object table content to determine which of the values in the specified value list violates the uniqueness constraint. Alternatively, if the INSERT statement contains a subquery, the object table contents addressed by that subquery must be matched against the object table contents to determine the cause of the problem.
For a DELETE statement, examine the dependent tables for unique constraints on foreign keys that are defined with the rule ON DELETE SET NULL. One such table has a foreign key column included in a unique index that cannot be set to null since there is already a null in the column for that table.
DataJoiner users: isolate the problem to the data source failing the request (refer to the Problem Determination Guide to determine which data source is failing to process the SQL statement) and examine the index definitions and data for the conditions listed previously.
sqlcode: -803
sqlstate: 23505
Cause: An error occurred while processing the current request.
Reason codes are interpreted as follows:
In SQL statements with host variables, use the host variable number to count in from the beginning of the statement (or substatement, in the case of compound SQL) to locate the invalid host variable. For statements using an SQLDA, the SQLVAR number is used to locate the invalid SQLVAR. For an input SQLDA, count only input host variables or SQLVARs; similarly for output. Note that this number is based at 1.
The statement cannot be processed.
Action: Examine the application program for any errors noted. Note that the programmer should not attempt to modify the precompiler output.
sqlcode: -804
sqlstate: 07002
Cause: Possible causes for this message (SQLCODE) are:
The statement cannot be processed.
Action: Specify the correct package name or bind the program. If the application being run is not bound to the database, contact the database administrator to do the necessary binding.
If the DB2 utility programs need to be rebound to the database, the database administrator can accomplish this by issuing one of the following CLP command from the bnd subdirectory of the instance, while connected to the database:
DataJoiner users: ensure that the packages required for DataJoiner are bound at the applicable data sources. Refer to the IBM DataJoiner Planning, Installation, and Configuration Guide for more information on binding packages DataJoiner uses to the data sources.
sqlcode: -805
sqlstate: 51002
Cause: The CONNECT statement originates from a source file which was precompiled having different connection options (SQLRULES, CONNECT type, SYNCPOINT, or RELEASE type) than that of a source file for which a connection exists.
Action: Ensure that all source files are precompiled using the same CONNECT options, or if this is not possible, call the SET CLIENT api to set the desired options for the application process before issuing the first CONNECT statement.
sqlcode: -808
sqlstate: 08001
Cause: One of the following caused the error:
DataJoiner users: this situation can be detected by DataJoiner or by the data source.
The statement cannot be processed.
Action: Ensure that the statement contains the proper condition specifications. If it does, there may be a data problem that is causing more than one row to be returned when only one is expected.
DataJoiner users: isolate the problem to the data source failing the request (refer to the Problem Determination Guide to determine which data source is failing to process the SQL statement) and examine the selection criteria and data for that object.
sqlcode: -811
sqlstate: 21000
Cause: The application attempted to execute an SQL statement that would result in updates to user data or to the subsystem catalog. This is prohibited for one of the following reasons:
These SQL statements include INSERT, UPDATE, DELETE, CREATE, ALTER, DROP, GRANT, and REVOKE.
The statement cannot be executed.
Action: If the application is running as an IMS inquiry-only transaction, see your IMS system programmer about changing the inquiry-only status of the transaction under which your application is running.
If the IMS or CICS application is attempting a remote update, either the application must be changed to run as a local application on the server DBMS, or the server DBMS must be upgraded to support two-phase commit.
If the application is attempting to update data at multiple locations, either the application must be changed, or all DBMSs involved must be upgraded to support two-phase commit.
sqlcode: -817
sqlstate: 25000
Cause: The timestamp generated by the precompiler at precompile time is not the same as the timestamp stored with the package at bind time.
This problem can be caused by the following:
DataJoiner users: in addition to the causes listed previously, the problem can also be due to not binding the DataJoiner packages at all applicable data sources.
The statement cannot be processed.
Action: Bind the application again, using the bind file for the program that matches the object module. Or, execute the program that corresponds to the package stored in the database.
If installing the sample database, record the number and text of this message and then contact your technical service representative.
DataJoiner users: in addition to the previously listed actions, ensure that the packages required for DataJoiner are bound at the applicable data sources. Refer to the IBM DataJoiner Planning, Installation, and Configuration Guide for more information on binding packages DataJoiner uses to the data sources.
sqlcode: -818
sqlstate: 51003
Cause: The application program placed an address that is not valid in the SQLDA.
The statement cannot be processed.
Action: Correct the application program so that valid addresses are placed in SQLDA.
sqlcode: -822
sqlstate: 51004
Cause: The number of items returned in the SELECT list exceeds the allowable maximum. The maximum for SELECT lists (other than on common table expressions) is 1012. The maximum for SELECT lists in common table expressions is 5000.
The statement cannot be processed.
Action: Determine whether all the information is actually needed. (Note that the number of items returned by the SELECT list * in the SQL statement SELECT * from A, B, C is the sum of the number of columns in all three tables.) If possible, rewrite the SQL statement so only the necessary items of information are returned. If all the information is necessary, break the SQL statement into two or more statements.
sqlcode: -840
sqlstate: 54004
Cause: SQLRULES(STD) is in effect and a CONNECT statement identifies an existing SQL connection.
Action: The correction depends on the error:
Correct the error in the application and try again.
sqlcode: -842
sqlstate: 08002
Cause: A statement, command, or API specified a server name that does not identify an existing SQL connection of the application process.
This may have occurred using:
Action: The correction depends on the error:
Correct the error in the application and try again.
sqlcode: -843
sqlstate: 08003
Cause: The application was precompiled with SYNCPOINT(TWOPHASE) and requires a Transaction Manager Database to coordinate the two phase commit. Reasons why the Transaction Manager Database is not available might include the following:
Action: Possible actions:
sqlcode: -859
sqlstate: 08502
Cause: The server database and client application are using codepages for different language types and any characters outside the 7-bit ASCII range cannot be guaranteed (only the characters in the 7-bit ASCII range exist in all codepages). For example, the connection might be between a Japanese and a Latin-1 codepage, but none of the Japanese characters will be available in the Latin-1 codepage, so all of these characters should be avoided (English characters are fine though).
DataJoiner users: possible causes are:
Action: Do not submit SQL statements or commands that use characters which are not common between the application and database codepages.
DataJoiner users: do not submit SQL statements or commands that use characters which are not common between the client system, the DataJoiner system, and the data source.
sqlcode: +863
sqlstate: 01539
Cause: The database chosen as the tm_database in the database manager configuration is not valid. The database must be at level DB2 V2.1 or later, and cannot be a database accessed through DRDA protocol (ie. through DB2 Connect).
The statement cannot be executed.
Action:
sqlcode: -865
sqlstate: 08001
Cause: Directory cataloging for a database caused a connection to be redirected in a manner which is not supported.
Possible reason codes are:
Action: By the reason code, the actions are:
sqlcode: -866
sqlstate: 08001
Cause: A current or dormant connection to a server exists, and an attempt to CONNECT to this server using the USER/USING clause is invalid.
Action: Possible actions:
sqlcode: -868
sqlstate: 51022