SQL Messages and Codes
SQL Messages and Codes
System i
Database
SQL messages and codes
Version 5 Release 4
System i
Database
SQL messages and codes
Version 5 Release 4
Note
Before using this information and the product it supports, read the information in “Notices,” on
page 189.
Note: By using the code examples, you agree to the terms of the “Code license and disclaimer
information” on page 187.
| Several additions were made to the “Listing of SQLSTATE class codes” on page 3, “Listing of SQLSTATE
| values” on page 4, and the Listing of SQL messages.
To help you see where technical changes have been made, this information uses:
v The image to mark where new or changed information begins.
v The image to mark where new or changed information ends.
To find other information about what’s new or changed this release, see the Memo to users.
Printable PDF
Use this to view and print a PDF of this information.
To view or download the PDF version of this document, select SQL messages and codes (about 2824KB).
| You need Adobe Reader installed on your system to view or print these PDFs. You can download a free
| copy from the Adobe Web site (www.adobe.com/products/acrobat/readstep.html) .
SQLCODE
An SQLCODE is a return code. The return code is sent by the database manager after completion of each
SQL statement.
Each SQLCODE that is recognized by a DB2 UDB for iSeries server has a corresponding message in the
message file QSQLMSG. The message identifier for any SQLCODE is constructed by appending the
absolute value (5 digits) of the SQLCODE to SQ and changing the third character to L if the first
character of the SQLCODE is 0. For example, if the SQLCODE is 30070, the message identifier is
SQ30070. If the SQLCODE is -0204, the message identifier is SQL0204. Lastly, if the SQLCODE is a 3-digit
positive number, a zero is added before the first digit. For example, if the SQLCODE is 551, the message
identifier is SQL0551.
SQLSTATE
SQLSTATE provides application programs with common return codes for success, warning, and error
conditions found among the DB2 Universal Database products. SQLSTATE values are particularly useful
when handling errors in distributed SQL applications. SQLSTATE values are consistent with the
SQLSTATE specifications contained in the SQL 1999 standard.
An SQLSTATE value is a return code that indicates the outcome of the most recently executed SQL
statement. The mechanism used to access SQLSTATE values depends on where the SQL statement is
executed. In Java™, SQLSTATE values are returned by using getSQLState() method. In SQL functions, SQL
procedures, SQL triggers, and embedded applications other than Java, SQLSTATE values are returned in
the following:
v The last five bytes of the SQLCA
v A stand-alone SQLSTATE variable
v The GET DIAGNOSTICS statement
SQLSTATE values are designed so that application programs can test for specific conditions or classes of
conditions.
SQLSTATE values are comprised of a two-character class code value, followed by a three-character
subclass code value. Class code values represent classes of successful and unsuccessful completion
conditions. If you want to use SQLSTATE as the basis of your application’s return codes, you can define
your own SQLSTATE classes or subclasses using the following guidelines:
v SQLSTATE classes that begin with the characters 7 through 9 or I through Z can be defined. Within
these classes, any subclass can be defined.
v SQLSTATE classes that begin with the characters 0 through 6 or A through H are reserved for the
database manager. Within these classes, subclasses that begin with the characters 0 through H are
reserved for the database manager. Subclasses that begin with the characters I through Z can be
defined.
The class code of an SQLSTATE value indicates whether the SQL statement was executed successfully
(class codes 00 and 01) or unsuccessfully (all other class codes).
SQLSTATE is related to SQLCODE. Every SQLSTATE has one or more SQLCODEs associated with it. An
SQLSTATE can refer to more than one SQLCODE.
When an SQLSTATE other than 00000 is returned from an application server that is not DB2 UDB for
iSeries, DB2 UDB for iSeries attempts to map the SQLSTATE to a DB2 UDB for iSeries SQLCODE and
message with the following results:
v If the SQLSTATE is not recognized by DB2 UDB for iSeries, the common message for the class is
issued.
v If the SQLSTATE and SQLCODE correspond to a single DB2 UDB for iSeries SQLCODE, DB2 UDB
attempts to convert the returned tokens into the replacement data that the SQL message expects. If an
error occurs while converting the tokens:
– The tokens are returned without conversion in the SQLERRM field of the SQLCA or in the SQL
diagnostics area.
– A common message for the class code of the SQLSTATE is issued.
Related reference
“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.
“Listing of SQLSTATE values” on page 4
The tables in this topic provide descriptions of SQLSTATE codes that can be returned to applications
by DB2 UDB for iSeries. The tables include SQLSTATE values, their meanings, and their
corresponding SQLCODE values.
SQL message finder
Table 11. Class code 0W: Prohibited Statement Encountered During Trigger
SQLSTATE
Value Meaning SQLCODE Values
0W000 The statement is not allowed in a trigger. -751
Table 13. Class code 20: Case Not Found for Case Statement
SQLSTATE
Value Meaning SQLCODE Values
20000 The case was not found for the CASE statement. -773
Table 34. Class code 42: Syntax Error or Access Rule Violation
SQLSTATE
Value Meaning SQLCODE Values
42501 The authorization ID does not have the privilege to perform the specified -551
operation on the identified object.
42502 The authorization ID does not have the privilege to perform the operation as -552
specified.
Table 42. Class code 57: Resource Not Available or Operator Intervention
SQLSTATE
Value Meaning SQLCODE Values
57005 The statement cannot be executed, because a utility or a governor time limit -666
was exceeded.
57006 The object cannot be created, because a DROP or CREATE is pending. -679
57007 The object cannot be used, because an operation is pending. -910
57011 Virtual storage or database resource is not available. -904, -971, -7053
57012 A non-database resource is not available. This will not affect the successful -30040
execution of subsequent statements.
57013 A non-database resource is not available. This will affect the successful -30041
execution of subsequent statements.
57014 Processing was canceled as requested. -952
57017 Character conversion is not defined. -332
57033 Deadlock or timeout occurred without automatic rollback. -913
57042 DDM recursion has occurred. -30001
57043 A local SQL application program cannot be executed on an application -7021
server.
To find a specific message, SQLCODE, or SQLSTATE, try the SQL message finder.
Detailed descriptions of all DB2 UDB for iSeries messages, including SQLCODEs, are available in
message file QSQLMSG. You can display and print them from the Display Message Description display.
The CL command to display the message description is DSPMSGD. This command shows you both the
first level and the second level text for the message. The first level is a short, single sentence version of
the message. The second level generally describes the reason in more detail and provides suggested
solutions.
To show the message that corresponds to SQLCODE 0204, type the following command:
DSPMSGD RANGE(SQL0204) MSGF(QSYS/QSQLMSG)
Related reference
You can use the following tables with both positive and negative SQLCODEs. Take the absolute value of
the SQLCODE, then append it to the letters SQL (for SQLCODEs less than 10 000) or the letters SQ (for
SQLCODEs greater than or equal to 10 000) to determine the message identifier. Each SQLCODE
corresponds to one or more SQLSTATEs.
SQ20054
Message Text: File &1 in &2 has DataLinks in link pending mode.
Cause Text: The accessed file &1 has DataLinks in link pending mode for reason code &3. The reason
codes are as follows: 21 - The status of the DataLinks cannot be verified. A file cannot be
used for INSERT and UPDATE statements while in link pending mode.
Recovery Text: Use the WRKPFDL (Work with Physical File DataLinks) command to determine which files
have DataLinks in link pending mode. Resolve the pending links and try the request again.
SQLCODE or -20054
SQLCODEs:
SQLSTATE or 55019
SQLSTATEs:
SQ20055
Message Text: Result column not compatible with column &1 in materialized query table.
Cause Text: The data type of a result column in the select list is not compatible with column &1 in the
materialized query table.
Recovery Text: Ensure that the data types of all SELECT result columns are compatible with the
corresponding existing columns of the materialized query table.
SQLCODE or -20055
SQLCODEs:
SQLSTATE or 42854
SQLSTATEs:
SQ20058
Message Text: Subselect for materialized query table &1 not valid for reason code &3.
SQ20093
Message Text: Attempt to ALTER table &1 in &2 failed. Reason code &3.
Cause Text: The ALTER request involving a materialized query table cannot be completed. Reason
codes and their meanings are:
v 2 - The ALTER specified DROP MATERIALIZED QUERY or ALTER MATERIALIZED
QUERY, but the specified table is not a materialized query table.
v 4 - The table has one or more triggers defined.
v 8 - The table is referenced in the definition of another materialized query table.
v 9 - The table is referenced directly or indirectly (such as through a view) in the SELECT
statement.
v 10 - The ALTER specified ADD MATERIALIZED QUERY, but the specified table is
already a materialized query table.
v 11 - The number of columns in the existing table does not match the number of columns
for the result of the SELECT statement.
v 12 - Column data types in the existing table do not match the column data types for the
result of the SELECT statement.
v 16 - The ALTER specified ADD MATERIALIZED QUERY, but the specified table has
more than one member.
Recovery Text: Change the ALTER statement, specify a different table, or change the SELECT statement to
specify different result columns. Try the request again.
SQLCODE or -20093
SQLCODEs:
SQLSTATE or 428EW
SQLSTATEs:
SQ20110
Message Text: Cannot implicitly connect to a remote site with a savepoint outstanding.
Cause Text: The statement referenced an object at a remote DBMS when an active savepoint exists.
SQ20112
Message Text: The maximum number of savepoints has been reached.
Cause Text: A resource limit has been exceeded.
Recovery Text: Issue a RELEASE TO SAVEPOINT or ROLLBACK TO SAVEPOINT before creating
additional savepoints. You may issue a COMMIT or ROLLBACK to release existing
savepoints.
SQLCODE or -20112
SQLCODEs:
SQLSTATE or 3B002
SQLSTATEs:
SQ20120
Message Text: SQL TABLE function must return a table result.
Cause Text: The RETURN statement in an SQL TABLE function must return a table result.
Recovery Text: Specify a query in the RETURN statement of a table function. Try the request again.
SQLCODE or -20120
SQLCODEs:
SQLSTATE or 428F1
SQLSTATEs:
SQ20141
Message Text: Truncation of value with length &1 occurred for &2.
Cause Text: On assignment of a value to a host variable or parameter, truncation occurred and the
length of the value that was truncated is too large to be returned in the indicator variable.
This situation can occur when truncation occurs on assignment of:
v A value to a parameter of a remote stored procedure and the value being truncated is
greater than 127 bytes. In this case, the indicator variable will contain a value of 127.
v A LOB value to a host variable and the value being truncated is greater than 32767 bytes.
In this case, the indicator variable will contain a value of 32767.
In these cases the actual length of the truncated value cannot be returned to the application
using the indicator variable. The actual length of the value is returned as message token
length.
Recovery Text: Change the length of the host variable or parameter and try the request again.
SQLCODE or +20141
SQLCODEs:
SQLSTATE or 01004
SQLSTATEs:
SQ20144
Message Text: Encryption password length not valid.
Cause Text: The length of the encryption password must be from 6 to 127 characters.
Recovery Text: Correct the length of the password value. Submit the request again.
SQLCODE or -20144
SQLCODEs:
SQLSTATE or 428FC
SQLSTATEs:
SQ20145
Message Text: The decryption function failed.
Cause Text: The password used for decryption does not match the password used to encrypt the data.
The data must be decrypted using the same password that was used to encrypt the data.
Recovery Text: Ensure that the same password is used to encrypt and decrypt the data.
SQLCODE or -20145
SQLCODEs:
SQLSTATE or 428FD
SQLSTATEs:
SQ20146
Message Text: The decryption function failed. The data is not encrypted.
Cause Text: The data must be a result of the ENCRYPT, ENCRYPT_RC2, or ENCRYPT_TDES function.
Recovery Text: Ensure that the data is a result of the ENCRYPT, ENCRYPT_RC2, or ENCRYPT_TDES
function. Data passed to a decryption function must be encrypted data.
SQLCODE or -20146
SQLCODEs:
SQLSTATE or 428FE
SQLSTATEs:
SQ20147
Message Text: The ENCRYPT function failed. Data is already encrypted.
Cause Text: An attempt was made to encrypt data that is already encrypted.
Recovery Text: Ensure that the data has not already been encrypted.
SQ20148
Message Text: RETURN statement must be specified in function &1 in &2.
Cause Text: A RETURN statement must be specified in an SQL function.
Recovery Text: Specify a RETURN statement. Try the request again.
SQLCODE or -20148
SQLCODEs:
SQLSTATE or 429BD
SQLSTATEs:
|| SQ20178
| Message Text: INSTEAD OF trigger not created for view &1.
| Cause Text: View &1 in &2 already has an INSTEAD OF trigger defined for the specified operation. A
| view can have only one INSTEAD OF trigger defined for each of the INSERT, UPDATE,
| and DELETE operations.
| Recovery Text: Drop the existing trigger. Combine the function for the existing trigger and the new trigger
| into a single trigger. Create the trigger again.
| SQLCODE or -20178
| SQLCODEs:
| SQLSTATE or 428FP
| SQLSTATEs:
|
|| SQ20179
| Message Text: Trigger cannot be created for view &1 that uses a WITH CHECK OPTION.
| Cause Text: View &1 in &2 specifies a WITH CHECK OPTION or is dependent on a view which has a
| WITH CHECK OPTION. An INSTEAD OF trigger cannot be defined for a view that has a
| WITH CHECK OPTION.
| Recovery Text: Remove the WITH CHECK OPTION from the view.
| SQLCODE or -20179
| SQLCODEs:
| SQLSTATE or 428FQ
| SQLSTATEs:
|
SQ20180
Message Text: Column &1 cannot be altered.
Cause Text: Column &1 is a partitioning key column for table &2 in &3 and cannot be altered.
Recovery Text: Change the table to a non-partitioned table before attempting to alter the column or remove
the ALTER COLUMN clause from the statement. Try the request again.
SQLCODE or -20180
SQLCODEs:
SQLSTATE or 428FR
SQLSTATEs:
SQ20200
Message Text: The install or replace of &1 in &2 failed because &3 could not be located.
Cause Text: The URL specified on the install or replace jar procedure did not identify a valid jar file.
Recovery Text: Reissue the install or replace jar procedure with a URL that identifies a valid jar file.
SQLCODE or -20200
SQLCODEs:
SQLSTATE or 46001
SQLSTATEs:
SQ20201
Message Text: The install, replace, or remove of &1 in &2 failed because the jar name is not valid.
Cause Text: The jar name specified on the install, replace, or remove jar procedure is not valid. For
example, the jar id may be of the improper format, may not exist to be replaced or
removed, or can not be installed as it already exists.
Recovery Text: Ensure the jar name is of the correct format. If the jar id exists, it may need to be removed
before it can be installed. For the remove or replace procedures, ensure the jar id exists.
SQLCODE or -20201
SQLCODEs:
SQLSTATE or 46002
SQLSTATEs:
SQ20202
Message Text: The replace or remove of &1 in &2 failed because &3 is in use.
Cause Text: The specified class in the jar file is currently in use by a defined procedure, or the
replacement jar file does not contain the specified class for which a procedure is defined.
Recovery Text: Ensure all procedures referencing the classes being removed are dropped and resubmit the
replace or remove procedure.
SQLCODE or -20202
SQLCODEs:
SQ20203
Message Text: Signature not valid for Java method in user defined function or procedure &1 in &2.
Cause Text: The signature of the Java method used to implement the function or procedure is not valid.
For example, the method may have parameters that are not compatible with the parameters
on the corresponding CREATE statement or the method for a procedure may specify a
return value.
Recovery Text: Reissue the corresponding CREATE statement specifying parameters that match the Java
method, or correct the parameters or return type of the Java method and rebuild the class.
SQLCODE or -20203
SQLCODEs:
SQLSTATE or 46007
SQLSTATEs:
SQ20204
Message Text: The user defined function or procedure &1 in &2 was unable to map to a single Java
method.
Cause Text: The identified function or procedure either failed to find a matching Java method, or found
more than 1 matching Java method.
Recovery Text: Correct either the Java method or corresponding create statement so that the function or
procedure call resolves to a single Java method.
SQLCODE or -20204
SQLCODEs:
SQLSTATE or 46008
SQLSTATEs:
SQ20205
Message Text: User defined function or procedure &1 in &2 has an input argument with a null value.
Cause Text: A function created with CALLED ON NULL INPUT or a procedure has an input parameter
with a null value but the Java data type for this argument does not support null values.
Examples of Java data types that do not support null values are BOOLEAN, BYTE, SHORT,
INT, LONG, or DOUBLE.
Recovery Text: If the method is to be called with null values, ensure the input Java types are capable of
accepting a null value. If &1 is a function, RETURNS NULL ON NULL INPUT may be
specified on the CREATE FUNCTION statement.
SQLCODE or -20205
SQLCODEs:
SQLSTATE or 39004
SQLSTATEs:
SQ20206
Message Text: The procedure &1 in &2 returned too many result sets.
Cause Text: The specified procedure returned more results sets than were specified on the procedure
definition.
SQ20207
Message Text: The install or remove jar procedure for &1 in &2 specified the use of a deployment
descriptor.
Cause Text: The DEPLOY or UNDEPLOY parameter of the install or replace jar procedure was
non-zero; this parameter is not supported and must be zero.
Recovery Text: Reissue the procedure with the DEPLOY or UNDEPLOY parameter set to zero.
SQLCODE or -20207
SQLCODEs:
SQLSTATE or 46501
SQLSTATEs:
|| SQ20214
| Message Text: Table designator &1 is not ordered.
| Cause Text: The ORDER OF clause was specified, but table designator &1 is not ordered.
| Recovery Text: Correct the ORDER OF clause. Try the request again.
| SQLCODE or -20214
| SQLCODEs:
| SQLSTATE or 428FI
| SQLSTATEs:
|
SQ20223
Message Text: The encryption or decryption function failed. Encryption facility not available.
Cause Text: An attempt to use function ENCRYPT, ENCRYPT_RC2, ENCRYPT_TDES, DECRYPT_BIN,
DECRYPT_BINARY, DECRYPT_BIT, DECRYPT_CHAR, DECRYPT_DB, or GETHINT failed
because the following product is not installed: 5722-AC3 IBM® Cryptographic Access
Provider 128-bit for iSeries.
Recovery Text: Install the encryption facility before using any encryption or decryption functions.
SQLCODE or -20223
SQLCODEs:
SQLSTATE or 560BF
SQLSTATEs:
SQ20224
Message Text: Encrypted data that was originally a binary string cannot be decrypted to a character
string.
Cause Text: The DECRYPT_CHAR function was invoked with an argument that represents an
encrypted string that was originally a binary string. A binary string cannot be cast to a
character string using the DECRYPT_CHAR function.
Recovery Text: The encrypted value can only be decrypted using the DECRYPT_BINARY function.
SQ20226
Message Text: The maximum number of stacked diagnostics areas has been exceeded.
Cause Text: The storage available to hold condition information items or to hold stacked diagnostics has
been exceeded.
Recovery Text: Modify the application logic so that fewer SQL warnings occur, or specify additional
condition areas using the SET TRANSACTION statement.
SQLCODE or -20226
SQLCODEs:
SQLSTATE or 0Z001
SQLSTATEs:
|| SQ20227
| Message Text: AS clause required for XMLATTRIBUTES or XMLFOREST function.
| Cause Text: The AS clause must be specified for argument &1 of the XMLATTRIBUTES or XMLFOREST
| function because the argument is not named. Argument &1 is specified as &2.
| Recovery Text: Specify an AS clause to name the argument. Try the request again.
| SQLCODE or -20227
| SQLCODEs:
| SQLSTATE or 42633
| SQLSTATEs:
|
SQ20228
Message Text: A STACKED diagnostic is not available.
Cause Text: A STACKED diagnostic is only accessible from a handler.
Recovery Text: Modify the application logic so that the STACKED diagnostic is only accessed from within
a handler.
SQLCODE or -20228
SQLCODEs:
SQLSTATE or 0Z002
SQLSTATEs:
SQ20235
Message Text: Alter of materialized query table &1 in &2 not valid.
Cause Text: A column of a materialized query table cannot be added, dropped, or altered.
Recovery Text: Change the statement to one that is valid or specify another table. Try the request again.
SQLCODE or -20235
SQLCODEs:
SQLSTATE or 428FY
SQLSTATEs:
SQ20243
Message Text: Index &1 cannot be both an encoded vector index and span all partitions.
Cause Text: An attempt was made to create index &1 as an encoded vector index and have it span all
partitions of a partitioned table. An encoded vector index can only be created over a single
partition of a partitioned table or over a non-partitioned table.
Recovery Text: Change the CREATE INDEX statement to remove either the NOT PARTITIONED clause or
the ENCODED VECTOR clause. Try the request again.
SQLCODE or -20243
SQLCODEs:
SQLSTATE or 42929
SQLSTATEs:
SQ20246
Message Text: &1 in &2 cannot be altered.
Cause Text: Table &1 is a partitioned table and cannot be altered because DDS-created logical file &3 in
&4 is based on the table.
Recovery Text: Remove the logical file. Try the request again.
SQLCODE or -20246
SQLCODEs:
SQLSTATE or 428G0
SQLSTATEs:
SQ20247
Message Text: Table &1 cannot be partitioned and contain an identity or ROWID column.
Cause Text: An attempt was made to create or alter table &1 in &2 in such a way that would create a
partitioned table that contained an identity column or ROWID column. A table cannot be
both partitioned and contain an identity column or ROWID column.
Recovery Text: Create the table with either an identity or ROWID column or as a partitioned table.
SQLCODE or -20247
SQLCODEs:
SQLSTATE or 429BH
SQLSTATEs:
SQ20251
Message Text: Partition &1 cannot be dropped.
SQ20268
Message Text: Sort sequence cannot be applied. Reason code &4.
Cause Text: Sort sequence table &2 in library &3 cannot be applied for reason code &4. The reason
codes and their meanings follow:
v 1 - The result of applying the sort sequence table to field &1 is greater than 32,742 bytes.
v 2 - The sort sequence table cannot be applied to the following functions: LOCATE,
POSITION and POSSTR.
v 3 - The sort sequence table cannot be applied to a LIKE predicate or %WLDCRD
function.
Recovery Text: Sort sequence table &2 is an International Components of Unicode (ICU) table. Recovery
for reason code 1: ICU sort sequence table results are longer than the fields they operate on.
If the field can contain SBCS data, the result of applying the sort sequence table can be 6
times the length of the field. Applying this sort sequence table to a DBCS field can be 3
times the length of the field. Either specify a smaller field or a non-ICU type sort sequence
table. Recovery for the other reason codes: Either omit the function or specify a non-ICU
type of sort sequence table.
SQLCODE or -20268
SQLCODEs:
SQLSTATE or 429BM
SQLSTATEs:
|| SQ20275
| Message Text: XML name &1 not valid.
| Cause Text: The XML name &1 is not valid for reason code &2. Reason codes are:
| v 1 - xmlns is used as an XML attribute name or as an XML namespace prefix for an XML
| element or attribute name.
| v 2 - The XML namespace prefix in a qualified XML name is not declared within its scope.
| v 3 - The XML name for an XML element or XML attribute is not an XML QName.
| Recovery Text: Specify a valid XML name. Try the request again.
| SQLCODE or -20275
| SQLCODEs:
| SQLSTATE or 42634
| SQLSTATEs:
|
|| SQ20276
| Message Text: XML namespace prefix &1 not valid.
SQ20326
Message Text: XML name &1 too long.
SQ30000
Message Text: Distributed Relational Database Architecture™ (DRDA) protocol error.
Cause Text: Command or SQL statement failed due to a distribution protocol error that will not affect
subsequent commands or SQL statements. The protocol error is &1 with a location code of
&2. The location codes are:
v ’01’X - The error was detected at the application requester.
v ’02’X - The error was detected at the application server.
A possible list of protocol errors is:
v ’121C’X - Not authorized to command.
v ’1245’X - Conversation protocol error. The error code is &3.
v ’124C’X - Data stream syntax error. The error code is &3.
v ’1254’X - Unexpected error condition. The error code is &3.
v ’125F’X - Application server does not support function requested.
v ’2202’X - Cursor not open.
v ’2204’X - Relational database not connected.
v ’2207’X - Relational database already connected.
v ’220A’X - Data descriptor not valid. The error code is &3.
v ’220E’X - Data descriptor did not match data.
v ’220F’X - Cursor already open.
v ’221D’X - Command not valid for conversation type.
If the protocol error does not appear in the list, refer to the DDM Architecture Reference for
DDM code point &1.
Recovery Text: If the protocol error is ’121C’X, then obtain the authorization required to use this command
or SQL statement at the application server. If the protocol error is not ’121C’X, then report
the problem using Analyze Problem (ANZPRB).
SQLCODE or -30000
SQLCODEs:
SQLSTATE or 58008
SQLSTATEs:
SQ30001
Message Text: Call to distributed SQL program not allowed.
Cause Text: An attempt was made to use Submit Remote Command (SBMRMTCMD) to call a
distributed SQL program from a Distributed Data Management (DDM) target job.
Recovery Text: Call the SQL program from a job that is not a DDM target job.
SQLCODE or -30001
SQLCODEs:
SQ30020
Message Text: Distributed Relational Database Architecture (DRDA) protocol error.
Cause Text: Command or SQL statement failed due to a distribution protocol error that will affect
subsequent SQL statements or commands. The application has been disconnected and the
process is in an unconnected state. The protocol error is &1 with a location code of &2. The
location codes are:
v ’01’X - The error was detected at the application requester.
v ’02’X - The error was detected at the application server.
A possible list of protocol errors is:
v ’1218’X - Unsupported function requested. The error code is &3.
v ’1232’X - Unexpected permanent error.
v ’1245’X - Conversation protocol error. The error code is &3.
v ’1254’X - Unexpected error condition. The error code is &3.
If the protocol error does not appear in the list, refer to the DDM Architecture Reference for
DDM code point &1.
Recovery Text: Report the problem using Analyze Problem (ANZPRB).
SQLCODE or -30020
SQLCODEs:
SQLSTATE or 58009
SQLSTATEs:
SQ30021
Message Text: Distributed relational database not supported by the remote system.
Cause Text: An attempt was made to connect to a Distribute Data Management (DDM) server that does
not support Distributed Relational Database Architecture (DRDA). On the remote system,
the DDM manager class was &1 with manager level &2.
Recovery Text: Change the program to connect to a relational database which supports DRDA.
SQLCODE or -30021
SQLCODEs:
SQLSTATE or 58010
SQLSTATEs:
SQ30040
Message Text: DDM resources at relational database &1 unavailable.
Cause Text: SQL statement or command failed due to an unavailable Distributed Data Management
(DDM) resource that will not affect subsequent SQL statements and commands. DDM
resource &2 is unavailable at relational database &1 with location code &3. The resource
codes are: ’1409’X - Communication buffer. The location codes are:
v ’01’X - Application requester or the local system.
v ’02’X - Application server.
Recovery Text: Free the DDM resource and try the request again.
SQLCODE or -30040
SQLCODEs:
SQ30041
Message Text: DDM resources at relational database &1 unavailable.
Cause Text: SQL statement or command failed due to an unavailable Distributed Data Management
(DDM) resource that will affect subsequent commands and SQL statements. The application
has been disconnected and the process is in an unconnected state. DDM resource &2 is
unavailable at relational database &1 with location code &3. The resource codes are:
v ’1409’X - Communication buffer.
v ’1410’X - Local build space.
v ’1411’X - DDM diagnostic area.
v ’1412’X - Local build space.
v ’1412’X - LOB build space.
The location codes are:
v ’01’X - Application requester or the local system.
v ’02’X - Application server.
Recovery Text: Free the DDM resource and try the request again.
SQLCODE or -30041
SQLCODEs:
SQLSTATE or 57013
SQLSTATEs:
SQ30050
Message Text: DDM command &1 not valid while bind process in progress.
Cause Text: An attempt was made to run Distributed Data Management (DDM) command &1. This
command is not valid while a bind process is in progress.
Recovery Text: Report this problem using the Analyze Problem (ANZPRB) command.
SQLCODE or -30050
SQLCODEs:
SQLSTATE or 58011
SQLSTATEs:
SQ30051
Message Text: Bind process for specified package name and consistency token not active.
Cause Text: Attempted to run a BNDSQLSTT or ENDBND Distributed Data Management (DDM)
command for a bind process that was not active.
Recovery Text: Report this problem using the Analyze Problem (ANZPRB) command.
SQLCODE or -30051
SQLCODEs:
SQLSTATE or 58012
SQLSTATEs:
SQ30052
Message Text: Program preparation assumptions not correct.
SQ30053
Message Text: Not authorized to create package for owner &1.
Cause Text: Attempt to create the package failed because you are not authorized to owner &1.
Recovery Text: Obtain the required authorization to &1 and try again.
SQLCODE or -30053
SQLCODEs:
SQLSTATE or 42506
SQLSTATEs:
SQ30060
Message Text: User is not authorized to relational database &1.
Cause Text: If relational database &1 is DB2 UDB for iSeries, a user exit program denied access to the
user, or a failure in the user exit program occurred.
Recovery Text: Obtain authorization to relational database &1 and try the request again.
SQLCODE or -30060
SQLCODEs:
SQLSTATE or 08004
SQLSTATEs:
SQ30061
Message Text: Relational database &1 not found.
Cause Text: Relational database &1 was either not in the relational database directory or defined at the
remote location.
Recovery Text: Do one of the following:
v Use the Add Relational Database Directory Entry (ADDRDBDIRE) command to add the
relational database name to the relational database directory.
v Change the relational database name to match the relational database directory entry.
v Verify the relational database name is defined on the remote location.
SQLCODE or -30061
SQLCODEs:
SQLSTATE or 08004
SQLSTATEs:
SQ30070
Message Text: Distributed Data Management (DDM) command &1 not supported.
SQ30071
Message Text: Distributed Data Management (DDM) object &1 not supported.
Cause Text: DDM object &1 was not supported.
Recovery Text: See previous messages for more information. See the DDM Architecture Reference for
additional information about code point &1.
SQLCODE or -30071
SQLCODEs:
SQLSTATE or 58015
SQLSTATEs:
SQ30072
Message Text: Distributed Data Management (DDM) parameter &1 not supported.
Cause Text: DDM parameter &1 is not supported. The location code is &2 with an error code of &3.
The location codes are:
v ’01’X - The error was detected at the application requester.
v ’02’X - The error was detected at the application server.
Recovery Text: See previous messages for more information. See the DDM Architecture Reference for
additional information about DDM parameter &1.
SQLCODE or -30072
SQLCODEs:
SQLSTATE or 58016
SQLSTATEs:
SQ30073
Message Text: Distributed Data Management (DDM) parameter value &1 not supported.
SQ30074
Message Text: Distributed Data Management (DDM) reply message &1 not supported.
Cause Text: DDM reply message &1 was not supported.
Recovery Text: See previous messages for more information. See the DDM Architecture Reference for
additional information about code point &1.
SQLCODE or -30074
SQLCODEs:
SQLSTATE or 58018
SQLSTATEs:
SQ30080
Message Text: Communication error occurred during distributed database processing.
SQ30082
Message Text: Authorization failure on distributed database connection attempt.
Cause Text: A connection attempt failed with reason code &2. The reason codes and their meanings are
as follows:
v 0 - Unknown cause.
v 1 - Password expired.
v 2 - Password not valid.
v 3 - Password missing.
v 4 - Protocol violation.
v 5 - User ID not found.
v 6 - User ID not valid. For a DB2 UDB for iSeries server, this could mean a damaged user
profile or PASSWORD(*NONE).
v 7 - User ID revoked or disabled.
v 15 - Security processing at the server failed.
v 16 - The new password is not valid.
v 17 - The security mechanism requested by the client is not supported or allowed at the
server. See recovery information below.
v 22 - Security processing at the client failed.
v 23 - CCSID conversion of the password failed.
SQ30089
Message Text: Communication error occurred during DB2 Multisystem processing.
Cause Text: A communication error occurred. A possible list of reasons may include:
v The remote system is not available.
v The communications network is not available.
v The userid used to start the connection may not exist on the remote system.
Recovery Text: See previous messages for more information. Check the status of the remote system and the
communications network for possible problems. Check QSYSOPR message queue for error
messages.
SQLCODE or -30089
SQLCODEs:
SQLSTATE or 08001
SQLSTATEs:
SQ30090
Message Text: Change request not valid for read-only application server.
Cause Text: Application requester requested a read-only application server. The running of a statement
which is not valid for a read-only application server was attempted. This message can
occur when initially attempting to connect to a non-iSeries server using interactive SQL
with the COMMIT option set to *NONE.
Recovery Text: Remove the change request from the program and try again. If the problem is due to the
use of COMMIT(*NONE) to a non-iSeries server, change to a different commitment control
level and try again.
SQLCODE or -30090
SQLCODEs:
SQLSTATE or 25000, 2D528, 2D529
SQLSTATEs:
SQ30104
Message Text: Bind option not valid.
|| SQ30106
| Message Text: The input data for a multiple row insert is not valid.
| Cause Text: A data error has been detected on the client when processing a row for a multi-row input
| operation. A null indicator value of -2 (X’FE’) was received from the client which indicates
| that the server should return an error SQLCA containing SQLSTATE 22527 over a null row.
| For an atomic multi-row input operation, such an error terminates processing of the
| multi-row input request, and any changes that have resulted from this request will be
| undone. For a non-atomic multi-row operation, such an error terminates processing of the
| multi-row input request, but any changes for this request are not undone.
| Recovery Text: Determine which part of the multi-row input operation is in error and retry the request.
| SQLCODE or -30106
| SQLCODEs:
| SQLSTATE or 22527
| SQLSTATEs:
|
SQ30107
Message Text: A request to release record read locks on close of cursor was ignored.
Cause Text: DB2 UDB for iSeries does not support this feature. To avoid this warning do the following.
For embedded SQL remove the WITH RELEASE clause from the CLOSE. For CLI remove
the option to define cursors with release.
Recovery Text:
SQLCODE or +30107
SQLCODEs:
SQLSTATE or 01662
SQLSTATEs:
SQL0007
Message Text: Character &1 (HEX &2) not valid in SQL statement.
Cause Text: The character &1 specified in the SQL statement is not permitted. The hexadecimal
representation for the character is &2. The character is ignored by the precompiler and
processing of the statement continues.
Recovery Text: Correct the character. The character may need to be enclosed either in quotation marks or
apostrophes. Precompile the program again.
| SQLCODE or -007
SQLCODEs:
SQL0010
Message Text: String constant beginning &1 not delimited.
Cause Text: The string delimiter is missing in the constant beginning with &1. The string is treated as if
it were delimited by the end of the source file.
Recovery Text: Delimit the string constant. Check for any missing or extra quotation marks and
apostrophes. These errors are likely to cause other errors. Some statements may not have
been processed as the result of either missing or extra string delimiters. Precompile the
program again.
| SQLCODE or -010
SQLCODEs:
| SQLSTATE or 42603
SQLSTATEs:
SQL0011
Message Text: Comment not closed.
Cause Text: A comment is not closed correctly with a comment delimiter. The comment is treated as if
it were closed by the end of source file.
Recovery Text: Make certain that the comment delimiter is specified properly and that it is between the
specified margins. This error is likely to cause other errors. Some statements may not have
been processed as a result of a missing comment delimiter. Precompile the program again.
SQLCODE or -011
SQLCODEs:
| SQLSTATE or 42601
SQLSTATEs:
SQL0012
Message Text: Correlation without qualification occurred for column &1 to table &2.
Cause Text: Column &1 which occurs in a subselect, is not explicitly qualified, and occurs in table &2 in
library &3 specified in the FROM clause of an outer subselect or as the target of an update
or delete operation. Consequently, the reference to the column in the subselect is an outer
reference, and correlation will occur.
Recovery Text: Ensure you intended to use the correlation. If you did not intend to use the correlation, the
column does not exist in any of the tables or views identified in the FROM clause of the
same level of the subselect that column &1 was referenced. Since it is a good practice to
explicitly qualify any intended correlated references, it is recommended that the statement
be changed so that the column &1 is qualified with a table designator.
SQLCODE or +012
SQLCODEs:
SQLSTATE or 01545
SQLSTATEs:
SQL0029
Message Text: INTO clause missing from embedded statement.
SQL0030
Message Text: Number of host variables less than result values.
Cause Text: The number of host variables specified in the INTO clause is less than the number of result
values. If the program is run, only the variables specified will have values assigned to
them.
Recovery Text: If all values should be received, specify the proper number of host variables. Precompile
the program again.
SQLCODE or +030
SQLCODEs:
SQLSTATE or 01503
SQLSTATEs:
SQL0051
Message Text: Cursor or procedure &1 previously declared.
Cause Text: One of the following has occurred:
v Cursor &1 has already been specified in a previous DECLARE CURSOR statement. A
cursor name must be unique within the program.
v Procedure &1 specified on a CALL statement is ambiguous.
Recovery Text: Make certain that the cursor names on all DECLARE CURSOR statements and the
procedure names on all DECLARE PROCEDURE statements are unique in the program.
Precompile the program again.
SQLCODE or -051
SQLCODEs:
SQLSTATE or 3C000
SQLSTATEs:
SQL0057
Message Text: RETURN statement in an SQL function must return a value.
Cause Text: A RETURN statement is specified in an SQL function without a return value. The return
value must be specified.
Recovery Text: Add a value to return. Try the request again.
SQLCODE or -057
SQLCODEs:
SQLSTATE or 42631
SQLSTATEs:
SQL0060
Message Text: Value &3 for argument &1 of &2 function not valid.
Cause Text: The length or scale specified as &3 for argument &1 of the &2 function is not valid. The
length specified for numeric values must be an unsigned integer from 1 through 63. The
scale specified for numeric values must be an unsigned integer between 0 and the specified
length.
Recovery Text: Correct the length or scale specified for the function. Try the request again.
SQLCODE or -060
SQLCODEs:
SQLSTATE or 42815
SQLSTATEs:
|| SQL0074
| Message Text: Descriptor COUNT &1 is not valid.
| Cause Text: A FETCH was attempted when the descriptor COUNT value does not match the number of
| columns in the result set.
| Recovery Text: Specify a different descriptor for the FETCH or specify a different COUNT value using the
| SET DESCRIPTOR statement.
| SQLCODE or -074
| SQLCODEs:
| SQLSTATE or 07008
| SQLSTATEs:
|
|| SQL0075
| Message Text: Descriptor item number &1 is not correct.
| Cause Text: Descriptor item number &1 is not correct for one of the following reasons:
| v The value given for the maximum number of items on an ALLOCATE DESCRIPTOR
| statement is not between 1 and 8000.
| v The item number given on a GET DESCRIPTOR or SET DESCRIPTOR statement is not
| between 1 and the maximum number of items assigned when the descriptor was
| allocated.
| Recovery Text: For the ALLOCATE DESCRIPTOR statement, ensure the maximum items specified is
| between 1 and 8000. For GET DESCRIPTOR and SET DESCRIPTOR statements, ensure the
| item number specified in VALUE is between 1 and the maximum number of items for the
| specified descriptor. Try the request again.
| SQLCODE or -075
| SQLCODEs:
SQL0078
Message Text: Parameter name required for routine &1 in &2.
Cause Text: Parameter name must be specified when creating SQL routines.
Recovery Text: Specify a parameter name. Try the request again.
SQLCODE or -078
SQLCODEs:
SQLSTATE or 42629
SQLSTATEs:
SQL0080
Message Text: Indicator variable &1 not SMALLINT type.
Cause Text: The definition of indicator variable &1 must be a 2-byte binary with a zero scale.
Recovery Text: Specify an indicator variable that is defined as a 2-byte binary with a zero scale. Try the
request again.
SQLCODE or -080
SQLCODEs:
SQLSTATE or 42978
SQLSTATEs:
SQL0084
Message Text: SQL statement not allowed.
SQL0087
Message Text: Variable cannot be NULL.
Cause Text: An SQL variable or parameter was specified in an SQL routine and is NULL. The variable
is specified in an SQL statement where NULL is not allowed.
Recovery Text: Assign a value to the SQL variable or parameter. Try the request again.
SQLCODE or -087
SQLCODEs:
SQLSTATE or 22004
SQLSTATEs:
SQL0090
Message Text: Host variable not permitted here.
Cause Text: Host variable &1 is not allowed as used in this statement. Host variables are not allowed:
v In a CREATE VIEW, CREATE TABLE, or ALTER TABLE statement.
v In any interactive SQL statement when the Statement processing value is *RUN or *VLD.
v In an SQL statement processed by the RUNSQLSTM command.
v In an INSERT, UPDATE, DELETE, or DECLARE CURSOR statement in REXX.
Recovery Text: Do one of the following and try the request again:
v Specify either a constant or a column name to replace the host variable. The colon
indicates that the name that follows is a host variable. Remove the colon to specify a
column name.
v If in interactive SQL, set the statement processing value to *SYN to syntax check a
statement that contains a host variable.
v If in REXX, change the host variables to parameter markers and prepare the INSERT,
UPDATE, DELETE, or DECLARE CURSOR statement.
SQLCODE or -090
SQLCODEs:
SQLSTATE or 42618
SQLSTATEs:
SQL0097
Message Text: Use of data type not valid.
Cause Text: The data type specified in the statement can not be specified for a procedure or function.
Data types such as LONG VARCHAR can only be specified for columns, and cannot be
specified for parameters.
Recovery Text: Correct the data type specified for the procedure or function. Try the request again.
SQLCODE or -097
SQLCODEs:
SQLSTATE or 42601
SQLSTATEs:
SQL0101
Message Text: SQL statement too long or complex.
Cause Text: The SQL statement is longer than the limit allowed for length or complexity. The reason
code is &1. One of the following reason codes indicates the error:
v 1 - The total number of subselects combined using UNION, EXCEPT, and INTERSECT is
greater than 256.
v 2 - The total number of columns, constants, and operators is greater than the SQL limits.
v 3 - The sum of the lengths of the non-LOB columns in a select list, table, view definition,
or user defined table function is greater than 32766 or the definition contains a LOB and
the sum of the lengths specified on the ALLOCATE clause for varying-length fields and
the non-varying field lengths is greater than 32740. The maximum length is reduced if
any of the columns are varying-length or allow null values.
v 4 - The total number of subselects referenced in an outer subselect is greater than 256.
v 5 - The total length of the statement text is greater than 2097152, or the total length of the
prepare attribute string text is greater than 65535.
v 6 - The relative position value specified on the FETCH statement is outside the range of
valid values.
v 7 - A system name could not be generated.
Recovery Text: Simplify the statement or divide the statement up into more than one statement and try the
request again. For reason code 7, specify a different name for the table, view, index, or alias.
SQLCODE or -101
SQLCODEs:
SQLSTATE or 54001, 54010, 54011
SQLSTATEs:
SQL0102
Message Text: String constant beginning with &1 too long.
Cause Text: The string constant beginning with &1 is larger than 32740 bytes. If this is a graphic string
constant, the string cannot be longer than 16370 DBCS characters.
SQL0103
Message Text: Numeric constant &1 not valid.
Cause Text: The token &1 begins with a digit, but the token is not a valid integer, decimal, or floating
point constant. Identifiers cannot begin with a digit except in a COBOL program or for the
WHENEVER statement in a FORTRAN program.
Recovery Text: Do one of the following and precompile the program again:
v Verify that token &1 is valid. Use apostrophes or quotation marks if a character constant
is required.
v Remove the character or characters that are not valid if a number is required.
SQLCODE or -103
SQLCODEs:
SQLSTATE or 42604
SQLSTATEs:
SQL0104
Message Text: Token &1 was not valid. Valid tokens: &2.
Cause Text: A syntax error was detected at token &1. Token &1 is not a valid token. A partial list of
valid tokens is &2. This list assumes that the statement is correct up to the token. The error
may be earlier in the statement, but the syntax of the statement appears to be valid up to
this point.
Recovery Text: Do one or more of the following and try the request again:
v Verify the SQL statement in the area of the token &1. Correct the statement. The error
could be a missing comma or quotation mark, it could be a misspelled word, or it could
be related to the order of clauses.
v If the error token is <end-of-statement> correct the SQL statement because it does not
end with a valid clause.
SQLCODE or -104
SQLCODEs:
SQLSTATE or 42601
SQLSTATEs:
SQL0105
Message Text: Mixed, graphic, or UTF-8 string constant not valid.
SQL0106
Message Text: Precision specified for FLOAT not valid.
Cause Text: The precision specified for the FLOAT column or parameter is not valid for floating point
data. The precision allowed is from 1-53. If 1-23 is specified, the column or parameter is
defined as single-precision floating point. If 24-53 is specified, the column or parameter is
defined as double-precision floating point.
Recovery Text: Change the precision specified. Try the request again.
SQLCODE or -106
SQLCODEs:
SQLSTATE or 42611
SQLSTATEs:
SQL0107
Message Text: &1 too long. Maximum &2 characters.
SQL0109
Message Text: &1 clause not allowed.
Cause Text: One of the following conditions was not allowed:
v Embedded SELECT statements cannot include the FOR UPDATE clause, the FOR READ
ONLY clause, the FOR FETCH ONLY clause, the OPTIMIZE clause, or the UNION,
EXCEPT or INTERSECT operator.
v SELECT statement used in cursor declarations or subselects cannot have an INTO clause.
v CREATE VIEW statements may not have an INTO, ORDER BY, FOR UPDATE, FOR
READ ONLY, FOR FETCH ONLY, or OPTIMIZE clause.
v INSERT statements may not have an INTO clause in a subselect, a FOR UPDATE, FOR
READ ONLY, FOR FETCH ONLY, or an OPTIMIZE clause.
v WHERE CURRENT OF cursor clause is not allowed in statements processed in
interactive SQL or statements processed by the RUNSQLSTM command.
v The NOT NULL clause is not allowed in the definition of a column being added to a
table unless a default value is specified.
v OVERRIDING USER VALUE and OVERRIDING SYSTEM VALUE are only valid if the
statement is changing a column that is defined with GENERATED ALWAYS.
v The RAISE_ERROR function cannot be specified alone in the select list or in a CASE
expression.
Recovery Text: Remove the clause. Try the request again.
SQLCODE or -109
SQLCODEs:
SQL0110
Message Text: Hexadecimal constant beginning with &1 not valid.
Cause Text: Either the hexadecimal constant &1 contains one or more characters that are not valid or
the number of characters between the string delimiters is not valid. All embedded blank
(X’40’) characters are removed from the string before verification is done. Hexadecimal
constants must contain an even number of characters. The length of a hexadecimal graphic
string must be a multiple of 4 to ensure that it contains a valid number of DBCS characters.
Hexadecimal constants representing MIXED data must have an even number of bytes
between the shift-out (X’0E’) and shift-in (X’0F’) characters and must have paired shift
characters. Hexadecimal graphic constants cannot contain a shift-out or a shift-in.
Recovery Text: Correct the constant. Ensure that the constant contains an even number of digits and that
the length for a hexadecimal graphic constant is a multiple of 4. The valid characters for
hexadecimal digits are characters 0 through 9 and uppercase or lowercase A through F.
Ensure MIXED data is in the correct format. Remove shift-out or shift-in characters from a
hexadecimal graphic constant. Try the request again.
SQLCODE or -110
SQLCODEs:
SQLSTATE or 42606
SQLSTATEs:
SQL0112
Message Text: Argument of function &1 contains another function.
Cause Text: The argument of column function &1 contains another column function. Only expressions
without column functions are allowed as arguments of a column function.
Recovery Text: Correct the function specification. Try the request again.
SQLCODE or -112
SQLCODEs:
SQLSTATE or 42607
SQLSTATEs:
SQL0113
Message Text: Name &1 not allowed.
SQL0114
Message Text: Relational database &1 not the same as current server &2.
Cause Text: Relational database &1 was specified in a 3 part name in the statement. However, either the
name is not the same as the current server &2, or the name is not the same as a relational
database name specified previously in the statement.
Recovery Text: Change the statement so the relational database name specified is the same as the current
server or so that all relational database names in the statement match.
SQLCODE or +114, -114
SQLCODEs:
SQLSTATE or 01536, 42961
SQLSTATEs:
SQL0115
Message Text: Comparison operator &1 not valid.
Cause Text: Simple comparison operators other than equal and not equal cannot be used with a list of
items. ANY, ALL, and SOME comparison operators must be followed by a fullselect, rather
than an expression or a list of items, and cannot be specified in a JOIN condition or in a
CASE expression.
Recovery Text: Change either the comparison or the operand. Try the request again.
SQLCODE or -115
SQLCODEs:
SQLSTATE or 42601
SQLSTATEs:
SQL0117
Message Text: Statement contains wrong number of values.
SQL0119
Message Text: Column &1 or expression in HAVING clause not valid.
Cause Text: One of the following has occurred:
v Column &1 specified in a HAVING clause is not within a column function and is not in
the GROUP BY clause.
v An expression specified in a HAVING clause is not within a column function and is not
in the GROUP BY clause.
Recovery Text: Remove the column or expression from the HAVING clause or add the column or
expression to the GROUP BY clause. Try the request again.
SQLCODE or -119
SQLCODEs:
SQLSTATE or 42803
SQLSTATEs:
SQL0120
Message Text: Use of function &2 not valid.
Cause Text: Function &2 cannot be used where it was specified:
v A column function or user-defined function sourced on a column function cannot be
specified in a SET clause, in a GROUP BY clause, in a JOIN condition, as the return
expression for a RETURN statement, or as an expression in a SET statement or VALUES
INTO statement. A column function or user-defined function sourced on a column
function is allowed in a WHERE clause only if the WHERE clause appears within a
subquery of a HAVING clause.
v An OLAP function cannot be specified in a WHERE clause, in a GROUP BY clause, in a
HAVING clause, or in a JOIN condition. An OLAP function cannot be specified as an
expression in a SET statement or VALUES INTO statement, in the SET clause of an
UPDATE statement, or as the return expression for a RETURN statement.
SQL0121
Message Text: Duplicate name &1 not allowed.
Cause Text: Name &1 is specified more than once in either the list of object columns of an INSERT
statement, in the SET clause of an UPDATE statement, or in the list of target host variables
in the SET or VALUES INTO statement. If the specified names are not the same then one of
the following has occurred:
v If the object is a view, the column they identify in the base table may be the same
column.
v The names may correspond to the same system column name.
Recovery Text: Do one of the following and try the request again:
v Remove the duplicate column.
v Specify a column list on the INSERT statement to remove the duplicate column.
SQLCODE or -121
SQLCODEs:
SQLSTATE or 42701
SQLSTATEs:
SQL0122
Message Text: Column &1 or expression in SELECT list not valid.
Cause Text: One of the following has occurred:
v The statement contains column name &1 and a column function in the SELECT clause
and no GROUP BY clause is specified.
v Column name &1 is specified in the SELECT clause but not in the GROUP BY clause.
v An expression is specified in the SELECT clause but not in the GROUP BY clause.
v A column or expression that is specified in the ORDER BY clause, but not in the SELECT
clause, does not conform to the grouping rules listed above.
Recovery Text: Do one of the following and try the request again:
v If a GROUP BY clause is required, make certain that all columns or expressions in the
SELECT list and ORDER BY clause are also in the GROUP BY clause.
v If a GROUP BY clause is not needed, the SELECT list and ORDER BY clause should not
contain column functions with column names.
SQLCODE or -122
SQLCODEs:
SQLSTATE or 42803
SQLSTATEs:
SQL0125
Message Text: ORDER BY column number &1 not valid.
Cause Text: The ORDER BY clause in the statement contains a column number that is either greater
than the maximum number of values that can be selected (8000), or is greater than the
number of columns in the result table select list.
SQL0128
Message Text: Use of NULL is not valid.
Cause Text: The keyword NULL is not valid with the operator specified. NULL is only allowed in a
predicate following IS or IS NOT. NULL is a reserved keyword and can only be used as the
name of a column if the name is delimited when used in an SQL statement.
Recovery Text: Either change the operator to IS or IS NOT or, if the word NULL was meant to be a column
name, specify the name within delimiters.
SQLCODE or -128
SQLCODEs:
SQLSTATE or 42601
SQLSTATEs:
SQL0129
Message Text: Too many tables in SQL statement.
Cause Text: The SQL statement contains too many tables or views. A single SQL statement can refer to a
maximum of 256 tables or views. This number includes the base tables of a view.
Recovery Text: Do one of the following and try the request again:
v Split the SQL statement into two or more simpler statements with a maximum of 256
tables in each.
v If this is a CREATE VIEW statement, reduce the number of tables to a maximum of 256.
SQLCODE or -129
SQLCODEs:
SQLSTATE or 54004
SQLSTATEs:
SQL0130
Message Text: ESCAPE character &1 or LIKE pattern is not valid.
Cause Text: Either ESCAPE character &1 is not valid or the use of the ESCAPE character in the LIKE
pattern is not valid. The ESCAPE character is not valid if:
v The length is not 1 SBCS character or 1 graphic character.
v The shift-in (X’0E’) and the shift-out (X’0F’) characters are specified.
The LIKE pattern is not valid if:
v The character string expression forming the pattern contains an ESCAPE character that is
not followed by a percent sign, an underscore, or another ESCAPE character.
v The graphic string expression forming the pattern contains an ESCAPE character that is
not followed by a DBCS percent sign, a DBCS underscore, or another ESCAPE character.
Recovery Text: Specify a valid LIKE pattern and ESCAPE character. Try the request again.
SQLCODE or -130
SQLCODEs:
SQL0131
Message Text: Operands of LIKE not compatible or not valid.
Cause Text: The arguments of the LIKE predicate must be character, binary, graphic, or numeric. One of
the following errors has occurred:
v The operand to the right of the LIKE operator is not character, binary, graphic, or
numeric.
v The operands of the LIKE predicate are not compatible.
v The ESCAPE character is not character, binary, or graphic.
Recovery Text: Ensure the operands for the LIKE predicate are character, binary, graphic, or numeric. The
ESCAPE character must be character, binary, or graphic. Try the request again.
SQLCODE or -131
SQLCODEs:
SQLSTATE or 42818
SQLSTATEs:
SQL0132
Message Text: LIKE predicate not valid.
Cause Text: Either the second operand or the ESCAPE character specified in a LIKE predicate is not
valid. The second operand must be a string or numeric expression. The ESCAPE character
must be a string expression but cannot be a special register.
Recovery Text: Change the incorrect operand or the operator. Try the request again.
SQLCODE or -132
SQLCODEs:
SQLSTATE or 42824
SQLSTATEs:
SQL0133
Message Text: Operator on correlated column in SQL function not valid.
Cause Text: An SQL column function appearing in a subquery of a HAVING clause is not valid if the
argument of the function is an expression that contains an operator (+, -, *, /, **), a
concatenation operator, or a scalar function that is applied to a correlated reference. An
operation cannot be performed on a correlated reference since the computed value of the
group cannot be determined in the outer (correlated) subselect without a possible value
from the inner subselect.
Recovery Text: If the operator is a scalar function, make the column function the argument of the scalar
function. Otherwise, remove the operator on the correlated reference or move the operator
so it is not in the argument of the column function. For example, specifying the expression
of the form: AVG( outertable.column1 + innertable.column2 ) is not valid, while the
expression AVG( outertable.column1 ) + innertable.column2 is valid.
SQLCODE or -133
SQLCODEs:
SQLSTATE or 42906
SQLSTATEs:
SQL0136
Message Text: ORDER BY, GROUP BY, or join columns too long.
Cause Text: The maximum number of elements in an ORDER BY list is 10000. The total length of all the
ORDER BY elements cannot exceed 32766 bytes. The maximum number of columns in a
GROUP BY list is 120. The total length of all the GROUP BY columns cannot exceed 32766
bytes. The total length of all the join columns in an exception join or outer join cannot
exceed 32766 bytes. If the ORDER BY or GROUP BY list contains null capable columns,
then an additional byte is required for each null capable column. If the ORDER BY or
GROUP BY list contains varying-length columns, then the 2 byte length is included in the
total length. If the allow copy data option is ALWCPYDTA(*NO), the total length of all the
GROUP BY columns cannot exceed 2000 bytes.
Recovery Text: The statement must be changed so that the length of the ORDER BY, GROUP BY, or join
values does not exceed their limits. One or more column names must be removed from the
clause. Try the request again.
SQLCODE or -136
SQLCODEs:
SQLSTATE or 54005
SQLSTATEs:
SQL0137
Message Text: Result too long.
Cause Text: A concatenation operator or a HEX scalar function was specified, but the resulting length of
the operation exceeds the maximum allowed. The maximum length is:
v 32766 bytes if the result is fixed-length character or fixed-length binary.
v 32740 bytes if the result is varying-length character or varying-length binary.
v 16383 DBCS characters if the result is fixed-length graphic.
v 16370 DBCS characters if the result is varying-length graphic.
v 2147483647 bytes if the result is a binary or character LOB.
v 1073741823 DBCS characters if the result is a double-byte character LOB.
SQL0138
Message Text: Argument &1 of substringing function not valid.
Cause Text: Argument 2 or 3 of the SUBSTRING function or argument 2 of the LEFT function is either
out of range or is an expression that does not evaluate to an integer.
v For the SUBSTRING function, argument 2 specifies the position of the first character of
the result and argument 3 specifies the length of the result. Argument 2 must be a valid
position of the first argument. Argument 3 must not exceed the length of argument 1
between argument 2 and the end of the string.
v For the LEFT function, argument 2 specifies the length of the result. Argument 2 must
not exceed the length of argument 1.
v If argument 1 is a character string or a binary string, a character is a byte, and if
argument 1 is graphic string, a character is a DBCS character.
v If the argument is *N, then one of the arguments is not valid but the argument number is
not known.
Recovery Text: If the argument is *N, display the previously listed messages in the job log (DSPJOBLOG
command) or press F10 (Display messages in job log) from this display to determine which
argument is in error. Change one or more of the arguments specified in the SUBSTR
function. The INTEGER scalar function may be used to convert the argument into an
integer result. Try the request again.
SQLCODE or +138, -138
SQLCODEs:
SQLSTATE or 01544, 22011
SQLSTATEs:
|| SQL0142
| Message Text: SET SESSION AUTHORIZATION statement is not allowed.
| Cause Text: Use of the SET SESSION AUTHORIZATION statement is restricted through this interface.
| Recovery Text: Use the SET SESSION AUTHORIZATION statement through a different interface.
| SQLCODE or -142
| SQLCODEs:
| SQLSTATE or 42612
| SQLSTATEs:
|
SQL0144
Message Text: Section number &1 not valid. Current high section number is &3. Reason &2.
Cause Text: Reason code is &2. Reason code 1, section number &1 has already been assigned. Reason
code 2, section number &1 is smaller than next possible number. Reason code 3, section
number on ENDBND is smaller than highest one assigned. Reason code 4, section number
is not in the SQL package. Reason code 5, section number of zero is not valid.
SQL0145
Message Text: Recursion not supported for application server other than iSeries.
Cause Text: Program &1 in &2 was called recursively when connected to an application server that is
not an iSeries. The program was connected to application server &3 with product
identification of &4. If the application server is an IBM product, the identification is in the
form pppvvrrm, where: ppp identifies the product as follows: DSN for DB2 UDB for
OS/390® and z/OS® ARI for VM and VSE QSQ for DB2 UDB for iSeries SQL for all other
DB2 products vv is a two-digit version identifier such as ’ 06 ’ rr is a two-digit release
identifier such as ’ 01 ’ m is a one-digit modification level such as ’ 0 ’ . For example, if the
application server is Version 6 Release 1 of DB2 UDB for OS/390 and z/OS, the value of
the product identification is ’ DSN06010 ’ .
Recovery Text: Change your application so that it is not recursively called when connected to a server
other than an iSeries.
SQLCODE or -145
SQLCODEs:
SQLSTATE or 55005
SQLSTATEs:
SQL0150
Message Text: View or logical file &1 in &2 read-only.
Cause Text: Update, delete, or insert is not allowed. &1 in &2 can be used only for read operations. A
view or logical file can be used only for read operations if one or more of the following
conditions are true:
v The view contains a DISTINCT keyword, GROUP BY clause, HAVING clause, or a
column function in the outer-most subselect.
v The view or logical file contains a join function.
v The view contains a subquery that refers to the same table as the table of the outer-most
subselect. A view of this type may be used for inserting rows.
v All the columns of the view are expressions, scalar functions, constants, or special
registers.
v All the columns of the logical file are input only.
v The select list of the view omits a column of the based on table that does not allow null
values or default values. Inserting into the view is not allowed.
Recovery Text: Change the statement to insert, delete, or update data into the base table of view &1. All
columns of the table that do not allow null values or default values must be assigned a
value when inserting a row into a table or view. Try the request again.
SQLCODE or -150
SQLCODEs:
SQLSTATE or 42807
SQLSTATEs:
SQL0151
Message Text: Column &1 in table &2 in &3 read-only.
SQL0152
Message Text: Constraint type not valid for constraint &1 in &2.
Cause Text: An attempt was made to drop constraint &1 in &2 using an ALTER TABLE statement. The
constraint was specified as CHECK, UNIQUE, PRIMARY, or FOREIGN KEY and is not the
same as the constraint found.
Recovery Text: Verify the name and type of the constraint you want to drop. Try the request again.
SQLCODE or -152
SQLCODEs:
SQLSTATE or 42809
SQLSTATEs:
SQL0153
Message Text: Column list required.
Cause Text: A column list must be specified because the result columns are unnamed. Result columns
are unnamed for one of the following reasons:
v An element of the SELECT list is not a column and the AS clause is not specified.
v Corresponding columns of the subselects in a UNION, EXCEPT, or INTERSECT do not
have the same name.
v Two result columns have the same column name. Every column name and
system-column name must be unique in a table or view definition. If two column names
are the same, the column name is &1.
Recovery Text: Do one of the following and try the request again:
v Provide a list of names for the columns in the table, view, or derived table.
v Specify an AS clause to assign a unique name to the unnamed elements or to rename the
duplicate columns in the SELECT list.
SQLCODE or -153
SQLCODEs:
SQLSTATE or 42908
SQLSTATEs:
SQL0155
Message Text: Transition table &1 read-only.
Cause Text: Statement is not allowed. Transition table &1 in an SQL trigger can be used only for read
operations.
SQL0156
Message Text: &1 in &2 not correct type.
Cause Text: A DROP TABLE, CREATE INDEX, LOCK TABLE, ALTER TABLE, CREATE TRIGGER or
ALTER PROCEDURE statement was specified but &1 in &2 is the wrong type. DROP
TABLE, CREATE INDEX, LOCK TABLE, and ALTER TABLE must specify a table. CREATE
TRIGGER for a BEFORE or AFTER trigger must specify a table. CREATE TRIGGER for an
INSTEAD OF trigger must specify a view. ALTER PROCEDURE must specify a procedure
that was created as LANGUAGE SQL.
Recovery Text: Change the statement to use the correct object type. Try the request again.
SQLCODE or -156
SQLCODEs:
SQLSTATE or 42809
SQLSTATEs:
SQL0157
Message Text: &1 in &2 not valid in FOREIGN KEY clause.
Cause Text: View or logical file &1 in &2 was specified in the REFERENCES clause in the definition of a
FOREIGN KEY referential constraint on a CREATE TABLE or an ALTER TABLE statement.
Views and logical files cannot be specified in a FOREIGN KEY clause.
Recovery Text: Specify the base table that contains the parent key in the FOREIGN KEY clause. Try the
request again.
SQLCODE or -157
SQLCODEs:
SQLSTATE or 42810
SQLSTATEs:
SQL0158
Message Text: Number of columns specified not consistent.
Cause Text: One of the following has occurred:
v The number of column names specified for a view in a CREATE VIEW statement is not
the same as the number of elements specified in the following SELECT clause.
v The number of column names specified for a table in a CREATE TABLE statement is not
the same as the number of elements specified in the following SELECT clause.
v The number of column names specified in a correlation clause is not the same as the
number of elements in the table, derived table, or table function.
v The number of column names specified in a column list of a common table expression is
not the same as the number of elements specified in the subselect.
v The number of columns specified in the RETURNS TABLE clause of a user defined table
function is not the same as the number of elements specified in the subselect in the
RETURN statement.
SQL0159
Message Text: &1 in &2 not correct type.
Cause Text: A DROP INDEX, DROP VIEW, DROP ALIAS, COMMENT ON INDEX, COMMENT ON
ALIAS, RENAME INDEX or REFRESH TABLE statement was specified but &1 in &2 is not
the correct type. DROP INDEX can only be used to drop an index. DROP VIEW can only
be used to drop a view. DROP ALIAS can only be used to drop an alias. COMMENT ON
INDEX can only be used to comment on an index. COMMENT ON ALIAS can only be
used to comment on an alias. RENAME INDEX can only be used to rename an index.
REFRESH TABLE can only be used to refresh a materialized query table.
Recovery Text: Do one of the following to correct the problem and try the request again:
v If this is a DROP statement:
– If &1 is an index, use a DROP INDEX statement.
– If &1 is a view, use a DROP VIEW statement.
– If &1 is a table, use a DROP TABLE statement.
– If &1 is an alias, use a DROP ALIAS statement.
v If this is a COMMENT ON INDEX or COMMENT ON ALIAS statement and &1 is a
table or view, use a COMMENT ON TABLE statement.
v If this is a RENAME INDEX statement and &1 is a table or view, use a RENAME TABLE
statement.
v If this is a REFRESH TABLE statement, specify a materialized query table.
SQLCODE or -159
SQLCODEs:
SQLSTATE or 42809
SQLSTATEs:
SQL0160
Message Text: WITH CHECK OPTION not allowed for view &1 in &2.
SQL0161
Message Text: INSERT or UPDATE not allowed because a resulting row does not satisfy view definition
&1 in &2.
Cause Text: The INSERT or UPDATE could not be done because a resulting row did not satisfy the
view definition for &1 in &2. Either the view or an underlying view contains a WITH
CHECK OPTION clause.
Recovery Text: Change the data being inserted or updated so that it conforms to the view definition.
SQLCODE or -161
SQLCODEs:
SQLSTATE or 44000
SQLSTATEs:
SQL0170
Message Text: Number of arguments for function &1 not valid.
Cause Text:
SQL0171
Message Text: Argument &1 of function &2 not valid.
Cause Text: The data type, length, or value of argument &1 of function &2 specified is not valid.
Recovery Text: Refer to the DB2 UDB for iSeries SQL Reference topic in the Information Center for more
information on scalar functions. Correct the arguments specified for the function. Try the
request again.
SQLCODE or -171
SQLCODEs:
SQLSTATE or 42815
SQLSTATEs:
SQL0175
Message Text: COMMIT, ROLLBACK, or SAVEPOINT failed.
Cause Text: A commit, rollback, savepoint failed due to reason code &2. The logical unit of work
identifier is &1. Reason codes and their meanings are:
v 1 - A transaction program error occurred.
v 2 - A commit resulted in a rollback.
v 3 - The requested transaction operation failed.
v 4 - The savepoint operation failed.
Recovery Text: Display the previous messages in the joblog and take the appropriate action.
SQLCODE or -175
SQLCODEs:
SQL0177
Message Text: CHECK condition text too long.
Cause Text: The CHECK condition text for a CHECK constraint is longer than 2000 bytes and does not
fit in the SYSCHKCST catalog view. The CHECK condition text cannot be stored in the
system catalog views. The CHECK_CLAUSE column of the SYSCHKCST catalog view will
contain the null values for this constraint.
Recovery Text: No recovery is necessary. If the complete text is required in the system catalog views,
consider using multiple CHECK constraints instead of one large CHECK constraint.
SQLCODE or +177
SQLCODEs:
SQLSTATE or 01009
SQLSTATEs:
SQL0178
Message Text: Query expression text for view &1 in &2 too long.
Cause Text: The query expression text for view &1 in &2 is longer than 10000 bytes and does not fit in
the SYSVIEWS catalog view. The statement text cannot be stored in the system catalog
views. The VIEW_DEFINITION column of the SYSVIEWS catalog view will contain the null
value for this view.
Recovery Text: No recovery is necessary. If the complete text is required in the system catalog views,
re-create the view with the length of the query expression less than or equal to 10000 bytes.
SQLCODE or +178
SQLCODEs:
SQLSTATE or 0100A
SQLSTATEs:
SQL0180
Message Text: Syntax of date, time, or timestamp value not valid.
Cause Text: The string representation of a date, time, or timestamp value does not conform to the
syntax for the specified or implied data type and format. &2 is either the character string
constant that is not valid or the column or host variable that contained the string. If the
name is *N, then the value is an expression specified in the statement. If the string was
found in a host variable, the host variable number is &1.
Recovery Text: Ensure that the date, time, or timestamp value conforms to the syntax for the data type it
represents. Try the request again.
SQLCODE or +180, -180
SQLCODEs:
SQLSTATE or 01534, 22007
SQLSTATEs:
SQL0181
Message Text: Value in date, time, or timestamp string not valid.
SQL0182
Message Text: A date, time, or timestamp expression not valid.
Cause Text: One of the following has occurred:
v An operand of addition is a date and the other is not a date duration.
v An operand of addition is a time and the other is not a time duration.
v An operand of addition is a timestamp and the other is not a duration.
v An operand of subtraction is a date and the other is not a date, character, or date
duration.
v An operand of subtraction is a time and the other is not a time, character, or time
duration.
v An operand of subtraction is a timestamp and the other is not a timestamp, character, or
duration.
Recovery Text: Correct the arithmetic expression so that it contains a valid date, time, or timestamp
expression. Try the request again.
SQLCODE or -182
SQLCODEs:
SQLSTATE or 42816
SQLSTATEs:
SQL0183
Message Text: Result of date or timestamp expression not valid.
SQL0184
Message Text: Parameter marker not valid in expression.
Cause Text: A parameter marker cannot be used as an operand in a date/time arithmetic expression.
Recovery Text: Correct the arithmetic expression. Try the request again.
SQLCODE or -184
SQLCODEs:
SQLSTATE or 42610
SQLSTATEs:
SQL0187
Message Text: Use of labeled duration not valid.
Cause Text: One of the following has occurred:
v A labeled duration is specified but is not the operand of the operators plus or minus.
v A labeled duration of years, months, or days is specified as the operand of addition or
subtraction and the other operand is not date or timestamp.
v A labeled duration of hours, minutes, or seconds is specified as the operand of addition
or subtraction and the other operand is not time or timestamp.
v A labeled duration of microseconds is specified as the operand of addition or subtraction
and the other operand is not timestamp.
v A labeled duration is specified as the left operand of subtraction.
v The value specified for the labeled duration is not a numeric type.
Recovery Text: Correct the use of the labeled duration. Try the request again.
SQLCODE or -187
SQLCODEs:
SQLSTATE or 42816
SQLSTATEs:
SQL0188
Message Text: &1 not a valid string representation of a name.
SQL0189
Message Text: Coded Character Set Identifier &1 not valid.
Cause Text: Coded Character Set Identifier (CCSID) &1 is not valid for one of the following reasons:
v The CCSID is not EBCDIC.
v The CCSID is not supported by the system.
v The CCSID is not valid for the data type.
v If the CCSID is specified for graphic data, then the CCSID must be a DBCS CCSID.
v If the CCSID is specified for UCS-2 or UTF-16 data, then the CCSID must be a UCS-2 or
UTF-16 CCSID.
v If the CCSID is specified for CLOB, DBCLOB or DATALINK data, then the CCSID must
not be 65535.
v If there are multiple DataLink columns with FILE LINK CONTROL, they must all have
the same CCSID.
v The NORMALIZED clause can only be specified for a UTF-8 or UTF-16 CCSID.
Recovery Text: Ensure that all CCSID values in the statement are supported by the system and are valid
for the data type. For a list of valid CCSID values, refer to the DB2 UDB for iSeries SQL
Reference topic in the Information Center, http://www.ibm.com/eserver/iseries/infocenter.
SQLCODE or -189
SQLCODEs:
SQLSTATE or 22522
SQLSTATEs:
SQL0191
Message Text: Mixed data or UTF-8 data not properly formed.
Cause Text: A mixed data string or UTF-8 data string does not have the proper format. For mixed data,
every shift-out character (’0E’X) must have a corresponding shift-in character (’0F’X). If
these characters are not paired, the data is not valid. The conversion was from column or
host variable &2 to column or host variable &4.
Recovery Text: Ensure that all mixed character data has paired shift characters and that all UTF-8 data is
valid. For more information about UTF-8, refer to the Programming support topic in the
Information Center.
SQLCODE or +191, -191
SQLCODEs:
SQLSTATE or 01547, 22504
SQLSTATEs:
SQL0194
Message Text: KEEP LOCKS not allowed.
Cause Text: KEEP LOCKS was specified for cursor &1 but is not allowed because the cursor is not
opened for read only. The cursor must be opened for read only to allow locks to be kept.
For an explanation of read only cursors, see the DB2 UDB for iSeries SQL Programming
topic in the Information Center, http://www.ibm.com/eserver/iseries/infocenter.
Recovery Text: Do not specify KEEP LOCKS, or specify a cursor that is read only.
SQLCODE or -194
SQLCODEs:
SQLSTATE or 42948
SQLSTATEs:
SQL0195
Message Text: Last column of &1 in &2 cannot be dropped.
Cause Text: An attempt was made to drop one or more columns using an ALTER TABLE statement.
The columns cannot be dropped from table &1 in &2 because at least one of the existing
columns must be preserved when altering a table.
Recovery Text: Ensure table &1 in &2 will have at least one column once the ALTER statement is complete.
Either remove the DROP of one of the columns and try the request again, or, if all of the
columns should be removed, drop the table and create it again.
SQLCODE or -195
SQLCODEs:
SQLSTATE or 42814
SQLSTATEs:
SQL0196
Message Text: Column &3 in &1 in &2 cannot be dropped.
Cause Text: An attempt was made to drop column &3. The column cannot be dropped because a view,
a constraint, or an index is dependent on the column and RESTRICT was specified, or the
column is part of the partition key.
Recovery Text: Specify CASCADE on the ALTER TABLE statement to drop the column and the views,
constraints, or indexes that are dependent on it. If the column is part of the partition key,
specify DROP PARTITIONING on the ALTER TABLE statement to remove the partitioning
for the table. Try the request again.
SQLCODE or -196
SQLCODEs:
SQLSTATE or 42817
SQLSTATEs:
SQL0198
Message Text: SQL statement empty or blank.
Cause Text: The SQL statement is empty or blank. One of the following has occurred:
v During precompiling, the SQL statement referred to has no text between the EXEC SQL
and the ending delimiter. The statement is ignored.
v While running a program containing SQL statements, the operand of a PREPARE or
EXECUTE IMMEDIATE statement is blank or empty. The operand, host variable, or
literal string that was the object of either the PREPARE or EXECUTE IMMEDIATE
statement contained all blanks or was an empty string.
Recovery Text: If precompiling, correct the statement or remove it and precompile the program again. If
running a program containing SQL statements, correct the logic of the program to make
certain that a valid SQL statement is provided before issuing a PREPARE or EXECUTE
IMMEDIATE statement.
SQLCODE or -198
SQLCODEs:
SQLSTATE or 42617
SQLSTATEs:
SQL0199
Message Text: Keyword &1 not expected. Valid tokens: &2.
Cause Text: The keyword &1 was not expected here. A syntax error was detected at keyword &1. The
partial list of valid tokens is &2. This list assumes that the statement is correct up to the
unexpected keyword. The error may be earlier in the statement but the syntax of the
statement seems to be valid up to this point.
Recovery Text: Examine the SQL statement in the area of the specified keyword. A colon or SQL delimiter
may be missing. SQL requires reserved words to be delimited when they are used as a
name. Correct the SQL statement and try the request again.
SQLCODE or -199
SQLCODEs:
SQLSTATE or 42601
SQLSTATEs:
SQL0203
Message Text: Name &1 is ambiguous.
SQL0204
Message Text: &1 in &2 type *&3 not found.
Cause Text: &1 in &2 type *&3 was not found. If the member name is *ALL, the table is not partitioned.
If this is an ALTER TABLE statement and the type is *N, a constraint or partition was not
found. If this is not an ALTER TABLE statement and the type is *N, a function, procedure,
trigger or sequence object was not found. If a function was not found, &1 is the service
program that contains the function. The function will not be found unless the external
name and usage name match exactly. Examine the job log for a message that gives more
details on which function name is being searched for and the name that did not match.
Recovery Text: Change the name and try the request again. If the object is a node group, ensure that the
DB2 Multisystem product is installed on your system and create a nodegroup with the
CRTNODGRP CL command. If an external function was not found, be sure that the case of
the EXTERNAL NAME on the CREATE FUNCTION statement exactly matches the case of
the name exported by the service program.
SQLCODE or +204, -204
SQLCODEs:
SQLSTATE or 01532, 42704
SQLSTATEs:
SQL0205
Message Text: Column &1 not in table &2 in &3.
Cause Text: A column with the name &1 does not exist in table or view &2 in schema &3.
SQL0206
Message Text: Column &1 not in specified tables.
Cause Text: &1 is not a column of table &2 in &3. If the table is *N, &1 is not a column of any table or
view that can be referenced.
Recovery Text: Do one of the following and try the request again:
v Ensure that the column and table names are specified correctly in the statement.
v If this is a SELECT statement, ensure that all the required tables were named in the
FROM clause.
v If the column was intended to be a correlated reference, qualify the column with the
correct table designator.
SQLCODE or -206
SQLCODEs:
SQLSTATE or 42703
SQLSTATEs:
SQL0208
Message Text: ORDER BY column &1 or expression not in result table.
Cause Text: Column &1 is specified in the ORDER BY clause and is not valid because it does not refer
to a named column of the result table when a UNION, EXCEPT, or INTERSECT operator is
specified. The result column is named if the corresponding columns in each SELECT list
have the same name.
Recovery Text: Do one of the following and try the request again:
v Ensure &1 is a named result column if UNION, EXCEPT, or INTERSECT is specified.
v Specify a numeric column identifier in place of &1 in the ORDER BY clause.
SQLCODE or -208
SQLCODEs:
SQLSTATE or 42707
SQLSTATEs:
SQL0213
Message Text: Parameter &1 not in routine &2 in &3.
Cause Text: A parameter with a name &1 does not exist in routine &2 in schema &3.
Recovery Text: Make certain that the parameter name, routine name, and any qualifiers are specified
correctly. Try the request again.
SQLCODE or -213
SQLCODEs:
SQLSTATE or 42703
SQLSTATEs:
SQL0214
Message Text: ORDER BY expression is not valid.
Cause Text: The expression in the ORDER BY clause in position &1 is not valid for reason code &3. 1 -
The SELECT statement contains a UNION, EXCEPT, or INTERSECT. 2 - DISTINCT is
specified in the SELECT clause and the expression or column cannot be matched exactly
with an expression or column in the select list. 3 - The select list uses a column function or
there is a GROUP BY clause and the expression is not a column function or does not match
exactly with an expression in the select list. 4 - A column function in the ORDER BY clause
requires grouping.
Recovery Text: Make the change listed for reason &3 and try the request again: 1 - Remove the expression
from the ORDER BY clause. 2 - Remove DISTINCT from the select clause or change the
ORDER BY expression or column to refer to a select list item by using a numeric column
identifier or a column name. 3 - Change the expression in the ORDER BY clause to a
column function or change to use a numeric column identifier or a column name. 4 - Add a
GROUP BY clause or remove the column function from the ORDER BY clause.
SQLCODE or -214
SQLCODEs:
|| SQL0216
| Message Text: Number of values in predicate lists do not match.
| Cause Text: The number of values on the left side of the predicate does not match the number of values
| on the right side of the predicate. If one side of the predicate is a fullselect that returns
| more than one result column, the other side of the predicate must be a list of expressions
| containing the same number of values. The fullselect must explicitly list the result columns.
| If both sides of the predicate are expression lists, the lists must contain the same number of
| values. An expression list used in an IN or NOT IN predicate cannot contain an untyped
| parameter marker.
| Recovery Text: Change the number of values in the predicate list or in the select list of a row fullselect so
| both sides contain the same number of values. Change a SELECT * in the fullselect to list
| the actual columns. Use a casting function for untyped parameter markers in an IN
| expression list.
| SQLCODE or -216
| SQLCODEs:
| SQLSTATE or 428C4
| SQLSTATEs:
|
SQL0221
Message Text: Number of rows &2 not valid.
Cause Text: A blocked FETCH, a blocked INSERT, or a SET RESULT SETS statement is not valid. The
number of rows specified is not between 0 and 32767 or is greater than the dimension of
the host structure array. The number of rows specified is &2 and the dimension of the array
is &3. If this is a FETCH statement, the cursor name is &1.
Recovery Text: Either ensure the number of rows is from 0 through 32767 and less than or equal to the
dimension of the array, or increase the size of the array.
SQLCODE or -221
SQLCODEs:
SQLSTATE or 42873
SQLSTATEs:
SQL0225
Message Text: FETCH not valid; cursor &1 not scrollable.
Cause Text: A FETCH statement was specified with PRIOR, FIRST, LAST, BEFORE, AFTER, CURRENT,
or RELATIVE for cursor &1, but cursor &1 is not scrollable. Only NEXT may be used for
cursors that are not scrollable.
Recovery Text: In order to specify PRIOR, FIRST, LAST, BEFORE, AFTER, CURRENT or RELATIVE on the
FETCH statement, the cursor must be scrollable. To create a scrollable cursor, add the
SCROLL keyword to the DECLARE CURSOR statement for cursor &1. SCROLL can also be
specified in the attributes string for the prepared statement associated with the cursor.
SQLCODE or -225
SQLCODEs:
SQLSTATE or 42872
SQLSTATEs:
SQL0227
Message Text: FETCH not valid, cursor &1 in unknown position.
Cause Text: A previous blocked FETCH for cursor &1 resulted in an error (SQLCODE &2, SQLSTATE
&3) in the middle of processing a block of rows retrieved from the database manager. One
or more rows left in the block could not be returned to the program following the error,
leaving the position of the cursor unknown. If the SQLSTATE is *N, the error is unknown.
Recovery Text: Close and reopen the cursor to set the position. For scrollable cursors, FIRST, LAST,
BEFORE, or AFTER may also be used to position the cursor.
SQLCODE or -227
SQLCODEs:
SQLSTATE or 24513
SQLSTATEs:
SQL0228
Message Text: FOR UPDATE clause not valid with SCROLL for cursor &1.
Cause Text: The FOR UPDATE clause and SCROLL keyword are specified for cursor &1. The FOR
UPDATE clause is not valid with the SCROLL keyword unless the DYNAMIC keyword is
also specified. If SCROLL is specified and DYNAMIC is not specified, the cursor is
read-only. If DYNAMIC SCROLL is specified, the cursor can be updated.
Recovery Text: To declare a scrollable cursor that is read-only, specify the SCROLL keyword but do not
specify the FOR UPDATE clause. To declare a scrollable cursor that can be updated, specify
DYNAMIC SCROLL. Precompile the program again.
SQLCODE or -228
SQLCODEs:
SQLSTATE or 42620
SQLSTATEs:
SQL0231
Message Text: Position of cursor &1 not valid for FETCH of current row.
Cause Text: A FETCH CURRENT or a FETCH RELATIVE 0 was specified for scrollable cursor &1. The
operation is not valid because the cursor is not positioned on a record. A FETCH of the
current row is not allowed following a FETCH BEFORE, a FETCH AFTER, or a FETCH that
resulted in an SQLCODE of +100.
Recovery Text: Ensure the cursor is positioned on a record before attempting to fetch the current row.
SQL0237
Message Text: Not enough SQLVAR entries were provided in the SQLDA.
Cause Text: The SQLDA only provided &2 SQLVAR entries. Since at least one of the columns being
described is a distinct type or a LOB, &3 SQLVAR entries should have been specified. None
of the secondary SQLVAR entries have been set. Since at least one of the columns is a
distinct type or a LOB, space should be provided for twice as many SQLVAR entries as the
number of columns. Only the base SQLVAR entries have been set.
Recovery Text: If there is no need for the additional information about the distinct type(s) or LOB(s), then
no action is required. If this information is needed, the value of the SQLN field in the
SQLDA should be increased to the value indicated in the message, and the statement
should be resubmitted.
SQLCODE or +237
SQLCODEs:
SQLSTATE or 01594
SQLSTATEs:
SQL0239
Message Text: Not enough entries were provided in the SQLDA or descriptor area.
Cause Text: The SQLDA or descriptor area only provided &1 entries. This is the number of SQLVAR
entries for the SQLDA or the value of DB2_MAX_ITEMS for a descriptor area. At least &2
entries should have been specified. None of the entries have been set. If a SQLDA is being
used, at least one of the columns being described is a distinct type or a LOB. For the
SQLDA, if any of the columns is a distinct type or a LOB, then space should be provided
for twice as many SQLVAR entries as the number of columns.
Recovery Text: For a descriptor, allocate more entries. For a SQLDA, if the distinct type or LOB
information is needed, the value of the SQLN field should be increased to the value
indicated in the message, and the statement should be resubmitted. If there is no need for
the additional information about the distinct type(s) or LOB(s), then it is possible to
resubmit the statement only providing enough SQLVAR entries to accommodate the
number of columns.
SQLCODE or +239
SQLCODEs:
SQLSTATE or 01005
SQLSTATEs:
SQL0242
Message Text: Duplicate partition name or number &1.
Cause Text: Partition name or partition number &1 was already specified. The partition name or
number must be unique.
Recovery Text: Specify a unique name or number for the partition. Try the request again.
SQLCODE or -242
SQLCODEs:
SQLSTATE or 42713
SQLSTATEs:
SQL0250
Message Text: Local relational database not defined in the directory.
Cause Text: One of the following has occurred:
v Three part names were used and the relational database name is not defined in the
relational database directory.
v A connect was attempted and the relational database name is not defined in the
relational database directory.
v The SQL statement uses the CURRENT SERVER special register and the local relational
database name is not defined in the relational database directory.
v The SQL statement referred to a view which used the CURRENT SERVER special register
and the the local relational database name is not defined in the relational database
directory.
Recovery Text: Define the local relational database name using the Add Relational Database Directory
Entry (ADDRDBDIRE) command.
SQLCODE or -250
SQLCODEs:
SQLSTATE or 42718
SQLSTATEs:
SQL0251
Message Text: Character in relational database name &1 not valid.
Cause Text: &1 contains either a #, @, ., or a $, which are not valid character for a relational database
name. Valid characters include A-Z, 0-9, and underscore.
Recovery Text: Correct the name. Try the request again.
SQLCODE or -251
SQLCODEs:
SQLSTATE or 2E000, 42602
SQLSTATEs:
SQL0255
Message Text: Function not supported for query.
SQL0256
Message Text: Constraint &1 in &2 not allowed on distributed file.
Cause Text: Constraint &1 in &2 not allowed for one of the following reasons: - The columns that make
up the partitioning key must be a subset of the columns that make up the foreign key. The
columns may appear in any order. - The node group of the dependent table in a foreign
key constraint must match the node group of the parent table.
Recovery Text: Ensure that every column that is in the partitioning key is also in the foreign key for the
table. Also ensure that the dependent table and the parent table are built over the same
nodegroup.
SQLCODE or -256
SQLCODEs:
SQLSTATE or 42998
SQLSTATEs:
SQL0270
Message Text: Function not allowed for table &1 in &2.
Cause Text: Table &1 in &2 is a distributed table or a partitioned table. The function is not allowed for
one of the following reasons: - The unique index or unique constraint is not allowed
because all unique indexes or unique constraints of a distributed table or a partitioned table
must contain all columns that make up the partitioning key. If this is a CREATE TABLE
statement and the PARTITIONING KEY clause was not specified, then the default
partitioning key is the first column of the primary key, or the first valid column of the
table. - Data in one of the partitioning key columns was changed by an UPDATE statement
which would have forced the row to a different node. - The table contains a LOB column.
LOB columns are not allowed in a distributed table. - The node group of the materialized
query table is different than the node group of one or more tables referenced by the
materialized query table. - A column of the result table is an XML type.
SQL0301
Message Text: Input host variable &2 or argument &1 not valid.
Cause Text: The value in relative position &1 in the statement is a type that is not compatible with the
requested operation. The value is host variable &2, entry &1 in a descriptor area, or
argument &2 in a CALL statement. A name *N indicates that a user’s descriptor area was
used or that a constant or special register was specified on the CALL statement.
Recovery Text: Do one of the following and try the request again:
v Use a host variable that is the correct type.
v Specify an argument in the CALL that is the correct type.
v Change the type specified for parameter &1 in the DECLARE PROCEDURE statement.
SQLCODE or -301
SQLCODEs:
SQLSTATE or 07006, 42895
SQLSTATEs:
SQL0302
Message Text: Conversion error on host variable or parameter &2.
Cause Text: Host variable or parameter &2 or entry &1 in a descriptor area contains a value that cannot
be converted to the attributes required by the statement. Error type &3 occurred. Error
types and their meanings are:
v 1 - Overflow.
v 2 - Floating point overflow.
v 3 - Floating point underflow.
v 4 - Floating point conversion error.
v 5 - Not an exact result.
v 6 - Numeric data that is not valid.
v 7 - Double-byte character set (DBCS) or UTF-8 data that is not valid.
v 8 - C NUL-terminator is missing for character host variables or double NUL-terminator is
missing for graphic host variables and the program was compiled with the *CNULRQD
option.
v 9 - Truncation when mapping a host variable or constant to a character or binary
parameter on a CALL statement.
v 10 - Incompatible conversion from the input SQLDATA value to the specified SQLTYPE
in a REXX application.
v 11 - Overflow on translation of UTF-8 character data. If the host variable name is *N and
the statement is FETCH, a descriptor area was specified. If the parameter name is *N and
the statement is CALL, a descriptor area, a constant, or a special register was specified.
Recovery Text: Change the value of the host variable or parameter or entry in the descriptor area so that it
can be converted and is valid. Try the request again.
SQL0303
Message Text: Host variable &2 not compatible.
Cause Text: A FETCH, SELECT, CALL, SET, VALUES INTO, GET DIAGNOSTICS, GET DESCRIPTOR,
or SET DESCRIPTOR cannot be performed because the data type of host variable &2 is not
compatible with the data type of the corresponding list item:
v When selecting a date value, a character host variable must be at least 6 bytes for a Julian
date, at least 8 bytes for a date in the MDY, YMD, DMY formats, or at least 10 bytes for
all other formats.
v When selecting a time value, a character host variable must be at least 8 bytes for a time
in the USA format and at least 5 bytes for all other formats.
v When selecting a timestamp value, a character host variable must be at least 19 bytes.
v If the host variable is C NUL-terminated and the program was compiled with
*CNULRQD option, then an additional byte is required for the NUL-terminator for
date/time values.
v For GET DIAGNOSTICS ALL, the host variable must be varying length character or
varying length graphic. The relative position of the host variable in the INTO clause, the
SQLDA, or the CALL statement is &1. If the host variable name is *N, a descriptor area
was specified on a FETCH statement.
Recovery Text: Ensure that the data types are compatible for each of the corresponding list items. Ensure
the host variables are defined correctly for date, time, and timestamp values.
SQLCODE or -303
SQLCODEs:
SQLSTATE or 22001, 42806
SQLSTATEs:
SQL0304
Message Text: Conversion error in assignment to host variable &2.
Cause Text: During an attempt to return a value to host variable &2 on a FETCH, an embedded
SELECT statement, a CALL statement, a SET statement, or a VALUES INTO statement.
error type &3 occurred. A list of the error types follows:
v 1 - Overflow.
v 2 - Floating point overflow.
v 3 - Floating point underflow.
v 4 - Floating point conversion error.
v 5 - Not an exact result.
v 6 - Numeric data that is not valid.
v 7 - Double-byte character set (DBCS) data that is not valid. The relative position of the
host variable is &1. If the host variable name is *N, a descriptor area was specified on the
FETCH or CALL statement.
Recovery Text: Change the size and, if necessary, the type of the host variable or entry in the descriptor
area so that it can contain the result value or correct the data that is not valid. Precompile
the program again.
SQLCODE or +304, -304
SQLCODEs:
SQL0305
Message Text: Indicator variable required.
Cause Text: A FETCH, embedded SELECT, CALL, GET DESCRIPTOR, or a SET or VALUES INTO
statement has resulted in a null value, but an indicator variable was not specified for host
variable &2. The relative position of the host variable in the INTO clause or parameter list
is &1. If the host variable name is *N, a descriptor area was specified. If this error occurs on
a GET DESCRIPTOR statement, the null value is being returned but the INDICATOR item
was not specified on the GET DESCRIPTOR statement.
Recovery Text: Specify an indicator variable, and precompile the program again. If this is a GET
DESCRIPTOR statement, specify both the DATA item and the INDICATOR item.
Precompile the program again.
SQLCODE or -305
SQLCODEs:
SQLSTATE or 22002, 22004
SQLSTATEs:
SQL0306
Message Text: REXX input host variable &1 not defined.
Cause Text: The REXX input host variable &1 appears in an SQL statement, but it is not defined
because a value has not been assigned to the variable.
Recovery Text: Verify that &1 is spelled correctly in the SQL statement and that a value is assigned to the
host variable before the SQL statement is run.
SQLCODE or -306
SQLCODEs:
SQLSTATE or 42863
SQLSTATEs:
SQL0311
Message Text: Length in a varying-length or LOB host variable not valid.
Cause Text: Host variable &2 was specified. The value in the length portion of the variable length or
LOB host variable is either negative or greater than the declared length. If the host variable
is graphic the length should be the number of DBCS characters. The host variable number
is &1. The specified length is &4. The variable is declared to have length &3.
Recovery Text: Change the length portion of the varying-length or LOB host variable to a valid positive
number or zero. Try the request again.
SQLCODE or -311
SQLCODEs:
SQLSTATE or 22501
SQLSTATEs:
SQL0312
Message Text: Variable &1 not defined or not usable.
SQL0313
Message Text: Number of host variables not valid.
Cause Text: The number of host variables or entries in an SQLDA or descriptor area specified in either
an EXECUTE or OPEN statement is not the same as the number of parameter markers
specified in the prepared SQL statement &1. If the statement name is *N, the number of
host variables or entries in a SQLDA or descriptor area was specified in an OPEN
statement and is not the same as the number of host variables specified in the DECLARE
CURSOR statement for cursor &2.
Recovery Text: Change the number of host variables specified in the USING clause or the number of
entries in the SQLDA or descriptor area to equal the number of parameter markers in the
prepared SQL statement or the number of host variables in the DECLARE CURSOR
statement. Precompile the program again.
SQLCODE or -313
SQLCODEs:
SQLSTATE or 07001, 07004
SQLSTATEs:
SQL0327
Message Text: Partitioning key does not correspond to a defined partition.
Cause Text: An INSERT, CREATE TABLE, or ALTER TABLE statement was attempted for a partitioned
table but the values supplied for the partitioning key did not qualify the row for any
partition.
Recovery Text: If the error occurred on an INSERT statement, change the values supplied for the row being
inserted so that they correspond to a partition of the table or alter the partition definition to
allow this key value. If the error occurred on a CREATE TABLE or ALTER TABLE
statement, alter the partition definitions so that all existing rows will fit in the table or
delete the rows which do not fit. Try the request again.
SQLCODE or -327
SQLCODEs:
SQLSTATE or 22525
SQLSTATEs:
SQL0328
Message Text: Column &1 not allowed in partitioning key.
Cause Text: Column &1 is not allowed to be part of the partitioning key. If the column name is *N, then
there are no valid columns for use as the default partitioning key for DB2 Multisystem
partitioning. Columns of type DATE, TIME, TIMESTAMP, FLOAT, DATALINK, and LOB or
a distinct type based on one of these types are not allowed in the partitioning key.
Recovery Text: Remove the column from the list of partitioning key columns, or change the data type of
the column.
SQL0329
Message Text: The SET PATH name list is not valid.
Cause Text: String constant or input host variable &1 contains a SET PATH name list that is not valid. A
host variable name *N indicates that an incorrect string constant was specified on the SET
PATH statement or for the SQLPATH on the SET OPTION statement. The name list must
have the following attributes:
v The length must be greater than 0.
v The length cannot be greater than 3483.
v It must contain a list of valid schema names, separated by commas.
v The list can contain a maximum of 268 schema names.
v Each schema name must be capitalized unless it is a delimited name.
v The list cannot contain the special values, *LIBL, CURRENT PATH, SYSTEM PATH or
USER.
Recovery Text: Use a string constant or host variable with the correct value.
SQLCODE or -329
SQLCODEs:
SQLSTATE or 0E000
SQLSTATEs:
SQL0330
Message Text: Character conversion cannot be performed.
Cause Text: An attempt was made to convert column or host variable &2 to column or host variable
&3. The conversion cannot be performed. If the source data is character and has a mixed
Coded Character Set Identifier (CCSID), then double-byte characters were found. These
mixed data conversions are only allowed if the source data does not contain any
double-byte data. If the data is graphic, the CCSID values are not compatible or the string
contains single-byte characters. The source CCSID is &4, and the target CCSID is &5.
Recovery Text: Ensure that all character or graphic comparison, concatenation, or assignment is between
columns or host variables with compatible CCSID values. If character data and the source
CCSID is mixed, the source data should not contain any double-byte characters. If graphic
data, the string cannot contain single-byte characters. Use a casting function like VARCHAR
to convert between character, DBCS graphic, and Unicode graphic data.
SQLCODE or -330
SQLCODEs:
SQLSTATE or 22021
SQLSTATEs:
SQL0331
Message Text: Character conversion cannot be performed.
SQL0332
Message Text: Character conversion between CCSID &1 and CCSID &2 not valid.
Cause Text: Character or graphic conversion has been attempted for data that is not compatible. There
is no conversion defined between CCSID &1 and CCSID &2. If one CCSID is 65535, the
other CCSID is a graphic CCSID. Conversion is not defined between 65535 and a graphic
CCSID. If this is a CONNECT statement, conversion is not defined between the default
application requester SBCS CCSID and the application server SBCS CCSID. If the second
CCSID is 0, the application server did not return its default SBCS CCSID. An application
server other than an iSeries may not support a CCSID of 65535.
Recovery Text: Ensure that all character or graphic comparisons, concatenation, or assignments are
between columns or host variables with compatible CCSID values. If this is a CONNECT
statement, change either the SBCS CCSID of the application requester or the application
server, so conversion between the CCSID values is defined.
SQLCODE or -332
SQLCODEs:
SQLSTATE or 57017
SQLSTATEs:
SQL0334
Message Text: Character conversion resulted in truncation.
Cause Text: Character conversion of column or host variable &2 has resulted in truncation. An attempt
was made to convert mixed ASCII data to mixed EBCDIC data or to convert UCS-2 or
UTF-16 graphic data to mixed EBCDIC data. The length of the data has increased due to
the insertion of shift characters. The resulting string did not fit in the target, and truncation
occurred.
Recovery Text: When converting from mixed ASCII to mixed EBCDIC or from UCS-2 or UTF-16 graphic to
mixed EBCDIC, ensure that there is enough space in the target.
SQLCODE or -334
SQLCODEs:
SQLSTATE or 22524
SQLSTATEs:
SQL0335
Message Text: Character conversion resulted in substitution characters.
SQL0336
Message Text: Identity or sequence attribute is not valid.
Cause Text: For an identity column or a sequence, the values specified for the START WITH,
INCREMENT BY, MINVALUE, MAXVALUE, and RESTART WITH options must have a
scale of zero.
Recovery Text: Change the value to one that is valid. Try the request again.
SQLCODE or -336
SQLCODEs:
SQLSTATE or 428FA
SQLSTATEs:
SQL0338
Message Text: JOIN predicate not valid.
Cause Text: The JOIN predicate is not valid because a column is specified that exists in a table that is
outside the scope of the join predicate. The scope is generally determined from left to right
but is also based on the position of the join-condition. If parentheses are used, columns
inside the parentheses can not come from a table outside the parentheses.
Recovery Text: Do one of the following and try the request again:
v Make certain that the column names, table names, and any qualifiers are specified
correctly.
v Specify parentheses around joined tables to specify a join order other than left to right.
Ensure columns exist in tables that are in the same scope.
SQLCODE or -338
SQLCODEs:
SQLSTATE or 42972
SQLSTATEs:
SQL0340
Message Text: Duplicate name &1 for common table expressions.
Cause Text: Name &1 cannot be used to define more than one table expression.
Recovery Text: Change the name for one of the common table expressions. Try the request again.
SQLCODE or -340
SQLCODEs:
SQL0341
Message Text: Cyclic references between common table expressions.
Cause Text: The common table expressions specified are not valid. The subselect for table &1 refers to
table &2 and the subselect for table &2 refers to table &1. Cyclic references between
common table expressions are not allowed.
Recovery Text: Change the common table expressions to refer to a table that exists or a common table
expression that has already been defined. Try the request again.
SQLCODE or -341
SQLCODEs:
SQLSTATE or 42835
SQLSTATEs:
|| SQL0342
| Message Text: Keyword not allowed in recursive common table expression &1.
| Cause Text: The common table expression &1 is recursive. The recursive common table expression
| contains one of the following errors:
| v A fullselect within the common table expression cannot start with SELECT DISTINCT
| because the common table expression is recursive.
| v A fullselect within the common table expression specified UNION instead of UNION
| ALL as required for recursive common table expressions.
| Recovery Text: Remove the keyword DISTINCT from the fullselect. Change the UNION to UNION ALL,
| or remove the recursive reference within the common table expression. Try the request
| again.
| SQLCODE or -342
| SQLCODEs:
| SQLSTATE or 42925
| SQLSTATEs:
|
|| SQL0343
| Message Text: Column list not valid for table.
| Cause Text: For a recursive common table expression:
| v The column name list must be specified following the table name of the common table
| expression. &1 is the common table expression name.
| v The sequence column name and the set cycle column name cannot be referenced in the
| column list of the recursive common table expression. &1 is the sequence column name
| or the set cycle column name.
| Recovery Text: Correct the recursive common table expression. Try the request again.
| SQLCODE or -343
| SQLCODEs:
| SQLSTATE or 42908
| SQLSTATEs:
|
|| SQL0345
| Message Text: Recursive common table expression &1 is not valid.
SQL0346
Message Text: Recursion not allowed for common table expressions.
Cause Text: The common table expression specified is not valid. The subselect for table &1 refers to
itself. Recursive common table expressions are not allowed.
Recovery Text: Change the common table expressions to refer to a table that exists or a common table
expression that has already been defined. Try the request again.
SQLCODE or -346
SQLCODEs:
SQLSTATE or 42836
SQLSTATEs:
SQL0348
Message Text: &1 expression not used correctly.
SQL0350
Message Text: Column &1 not valid.
Cause Text: One of the following errors has occurred:
v A LOB or DataLink column is not valid as a key field, the key of an index, or the foreign
key of a referential constraint.
v A DataLink column with the FILE LINK CONTROL option cannot be in a table in
QTEMP, QSYS, QSYS2, or SYSIBM, or in a temporary table.
v A LOB or DataLink column or a distinct type based on a LOB or Datalink type is not
valid as a partitioning key column for RANGE partitioning.
Recovery Text: Remove the LOB or DataLink column from the specification of the table, index, key, or
constraint.
SQLCODE or -350
SQLCODEs:
SQLSTATE or 42962
SQLSTATEs:
SQL0351
Message Text: The AR is not at the same level and DB2 cannot transform the data type to a compatible
type.
SQL0352
Message Text: The AS is not at the same level and DB2 cannot transform the data type to a compatible
type.
Cause Text: The data type of entry &1 is not supported on the Application Server. The Application
Server is at less than Level 6 for the SQL Access Manager, and the Application Requester
cannot transform the data type to a compatible type.
Recovery Text: Change the data type to one that is supported by the corresponding Application Server.
SQLCODE or -352
SQLCODEs:
SQLSTATE or 56084
SQLSTATEs:
SQL0357
Message Text: File server &1 used in DataLink not currently available.
Cause Text: Server &1 in the URL of the DataLink value is not available for reason code &2. The reason
codes are as follows:
v 1 - The file server in a Datalink value is not available.
v 2 - The database server, instance, or database from which the operation was attempted is
not registered with the file server.
v 3 - Restart recovery is pending or is in progress on a file server involved in the
operation.
v 4 - The file server in a Datalink value is registered with the database but is an unknown
server.
Recovery Text: Verify that the server is running and can be accessed. Try the request again.
SQLCODE or -357
SQLCODEs:
SQLSTATE or 57050
SQLSTATEs:
SQL0358
Message Text: Error &1 occurred using DataLink data type.
SQL0359
Message Text: Value for identity column or sequence not available.
Cause Text: The value for the identity column or sequence is not available for one of the following
reasons:
v The INSERT or UPDATE statement cannot be run because all values for the identity
column have already been assigned.
v The NEXT VALUE expression cannot be evaluated because all values for the sequence
have already been assigned.
Recovery Text: For identity columns, alter the column to allow a larger range of values for the identity
column or alter the column to allow for cycling of identity values. For sequences, alter the
sequence to allow a larger range of values or to allow cycling of the sequence.
SQLCODE or -359
SQLCODEs:
SQLSTATE or 23522
SQLSTATEs:
SQL0360
Message Text: DataLink in table &1 in &2 may not be valid due to pending links.
Cause Text: Table &1 in schema &2 has DataLinks in link pending mode. While the DataLink can be
retrieved using FETCH or SELECT INTO, the DataLink may not be valid because the table
has DataLinks in link pending mode.
Recovery Text: Verify that the value retrieved is a valid URL. The command WRKPFDL (Work with
Physical File DataLinks) can be used to determine which tables have DataLinks in link
pending mode.
SQLCODE or +360
SQLCODEs:
SQLSTATE or 01627
SQLSTATEs:
SQL0373
Message Text: DEFAULT cannot be specified for column &1.
Cause Text: One of the following has occurred:
v The DEFAULT clause is specified for an IDENTITY column or ROWID column on the
CREATE TABLE or ALTER TABLE statement.
v A SET statement is specified in an SQL trigger that assigns DEFAULT to an IDENTITY
column or a ROWID column that was defined as GENERATED BY DEFAULT.
Recovery Text: Remove the DEFAULT clause from the definition of the column or change the SET
statement so it does not assign a value of DEFAULT. Try the request again.
SQLCODE or -373
SQLCODEs:
SQLSTATE or 42623
SQLSTATEs:
SQL0385
Message Text: SQL routine &1 in &2 created with assignment to SQLCODE or SQLSTATE.
Cause Text: SQL routine &1 in schema &2 was created, but contains an assignment statement that
specifies the SQLCODE or SQLSTATE variable as the target. Assignment statements that
modify SQLCODE and SQLSTATE only change the value in the variable, the error or
warning is not signaled.
Recovery Text: No recovery is necessary. If the intent was to signal an error or warning, specify the
SIGNAL or RESIGNAL statement instead of the assignment.
SQLCODE or +385
SQLCODEs:
SQLSTATE or 01643
SQLSTATEs:
SQL0387
Message Text: No additional result sets returned.
Cause Text: Procedure &1 in &2 was defined to return a maximum number of &4 result sets. The
procedure returned &3 result sets.
Recovery Text: None.
SQLCODE or +387
SQLCODEs:
SQLSTATE or 02001
SQLSTATEs:
SQL0391
Message Text: Table function cannot be argument of function &1.
Cause Text: The table designator for a table function cannot be used as the argument of function &1 in
schema &2.
Recovery Text: Use a table designator that does not represent a table function as the argument of this
function. Try the request again.
SQLCODE or -391
SQLCODEs:
SQLSTATE or 42881
SQLSTATEs:
SQL0392
Message Text: Assignment of LOB to specified host variable not allowed.
Cause Text: The target host variable for all fetches of this LOB value for cursor &1 must be a locator or
a LOB host variable.
Recovery Text: Change the target of this fetch to either a LOB host variable or a LOB locator to be
consistent with other fetches for this cursor. If it is necessary to use both LOB host variables
and LOB locators as targets for this fetch, use the *NOOPTLOB compiler option.
SQLCODE or -392
SQLCODEs:
SQLSTATE or 42855
SQLSTATEs:
SQL0393
Message Text: Value specified for condition or diagnostic is not valid.
Cause Text: The value specified for the DIAGNOSTICS SIZE on the SET TRANSACTION statement is
out of range, or the condition number specified on the GET DIAGNOSTICS statement is
greater than the number of conditions available for the previous SQL statement.
Recovery Text: Specify a correct value.
SQLCODE or -393
SQLCODEs:
SQL0398
Message Text: AS LOCATOR cannot be specified for a non-LOB parameter.
Cause Text: AS LOCATOR is only allowed for LOB parameters to a procedure or function.
Recovery Text: Use AS LOCATOR only for a LOB parameter to a procedure or function.
SQLCODE or -398
SQLCODEs:
SQLSTATE or 428D2
SQLSTATEs:
SQL0399
Message Text: Value for ROWID column &1 not valid.
Cause Text: The INSERT or UPDATE statement cannot be run because the value specified for ROWID
column &1 is not valid.
Recovery Text: Remove column &1 from the column list or specify a valid ROWID value or DEFAULT for
column &1.
SQLCODE or -399
SQLCODEs:
SQLSTATE or 22511
SQLSTATEs:
SQL0401
Message Text: Comparison operator &1 operands not compatible.
Cause Text: The operands of comparison operator &1 are not compatible:
v Numeric operands are compatible with any other numeric operands and with character
and graphic operands.
v Character operands are compatible with operands that are character, graphic, date, time,
timestamp, or numeric.
v Date, time, and timestamp operands are compatible with character and graphic operands
or with another operand of the same type.
v Graphic operands are compatible with graphic, character, date, time, timestamp, or
numeric operands.
v Binary operands are compatible only with binary operands.
v Operands that are user-defined types can only be compared to operands that are the
same exact type.
v DataLink and XML operands cannot be compared.
Recovery Text: Check the data types of all operands to see if the data types are compatible. If all the
operands of the SQL statement are correct and a view is being accessed, then check the data
types of all the operands in the view definition. Correct the errors. Try the request again.
SQLCODE or -401
SQLCODEs:
SQLSTATE or 42818
SQLSTATEs:
SQL0403
Message Text: Alias &1 in &2 created but table or view not found.
Cause Text: The alias &1 was created in &2, but the referenced table or view, &3 in &4, could not be
found.
Recovery Text: The alias was created, but cannot be used until &3 in &4 is created.
SQLCODE or +403
SQLCODEs:
SQLSTATE or 01522
SQLSTATEs:
SQL0404
Message Text: Value for column or variable &1 too long.
Cause Text: An INSERT or UPDATE statement or a SET or VALUES INTO statement or a GET
DIAGNOSTICS statement specifies a value that is longer than the maximum length string
that can be stored in &1. The length of &1 is &2 and the length of the string is &3.
Recovery Text: Reduce the length of the string from &3 to a maximum of &2 and try the request again.
SQLCODE or -404
SQLCODEs:
SQLSTATE or 22001
SQLSTATEs:
SQL0405
Message Text: Numeric constant &1 out of range.
SQL0406
Message Text: Conversion error on assignment to column &2.
Cause Text: During an attempt to assign a value to column &2 with an INSERT, UPDATE, ALTER
TABLE, or REFRESH TABLE statement, conversion error type &3 occurred. If precompiling,
the error occurred when converting a numeric constant to the same attributes as column
&2. A list of the error types follows:
v 1 - Overflow.
v 2 - Floating point overflow.
v 3 - Floating point underflow.
v 4 - Floating point conversion error.
v 5 - Not an exact result.
v 6 - Numeric data that is not valid.
v 7 - Double-byte character set (DBCS) data that is not valid.
Recovery Text: Change the statement so that the result value fits in column &2 and is valid, or create the
table or view again, specifying a new type or length for column &2 so that the result value
can be assigned.
SQLCODE or -406
SQLCODEs:
SQLSTATE or 22003, 22023, 22504
SQLSTATEs:
SQL0407
Message Text: Null values not allowed in column or variable &5.
SQL0408
Message Text: Value for column or variable &1 not compatible.
Cause Text: The data type of the source value is not compatible with the data type of the target column
or variable &1. If the statement is INSERT or UPDATE, &1 is a column in table &2 in
schema &3.
v Any numeric type value can be assigned to any numeric, character, or graphic type.
v Any character or graphic value can be assigned to any character, graphic, or numeric
type.
v Any binary value can be assigned to any binary type.
v A date, time, or timestamp value can be assigned to any character or graphic type.
v Any character or graphic value can be assigned to a date, time, or timestamp type.
v A date value can be assigned to a date.
v A time value can be assigned to a time.
v A timestamp value can be assigned to a timestamp.
v A value being assigned to a user-defined type must be promotable to the source type.
v The DLVALUE function must be specified when assigning to a DataLink.
Recovery Text: Change the column, host variable, constant, or function assigned to &1 to one that is
compatible. Try the request again.
SQLCODE or -408
SQLCODEs:
SQL0410
Message Text: Floating point literal &1 not valid.
Cause Text: The number of characters in the floating point constant &1 cannot exceed 24 excluding
leading zeros. The number of digits in the first number cannot exceed 17 excluding leading
zeros, and the number of digits in the second number cannot exceed 3.
Recovery Text: Correct the indicated literal &1. Make certain that the floating point literal is in the correct
form shown by the following examples: +1.2E+3, 15E1, 2.E5, 2.2e-1, +5.E+2, -.1e1. Try the
request again.
SQLCODE or -410
SQLCODEs:
SQLSTATE or 42820
SQLSTATEs:
SQL0412
Message Text: Subselect with more than one result column not valid.
Cause Text: The subselect of a predicate must have one result column specified in its SELECT list when
the other operand of the predicate is a single expression. The result of the subselect can be
zero, one, or many rows to form a list, but it must have only one result column.
Recovery Text: Change the number of items in the SELECT list of the subselect so only one result column
is specified or change the other operand of the predicate to be a list of expressions.
SQLCODE or -412
SQLCODEs:
SQLSTATE or 42823
SQLSTATEs:
SQL0414
Message Text: Operand not valid in LIKE predicate.
Cause Text: Operand 1 of a LIKE predicate has a type of date, time, timestamp, or DataLink or is a
user-defined type. Operands specified in LIKE predicates must be binary, character, graphic,
or numeric. If the ESCAPE character is specified, operand 1 cannot be DBCS-only. If the
operand is a column, the column name is &1.
Recovery Text: Change operand 1 of the LIKE predicate to be a binary, character, graphic, or numeric type.
Use a different predicate for date, time, or timestamp comparisons. Do not specify an
ESCAPE character if operand 1 is DBCS-only. Try the request again.
SQLCODE or -414
SQLCODEs:
SQLSTATE or 42824
SQLSTATEs:
SQL0415
Message Text: UNION, EXCEPT, or INTERSECT operands not compatible.
SQL0417
Message Text: Combination of parameter markers not valid.
Cause Text: The statement string specified as the object of a PREPARE statement contains a predicate or
expression where parameter markers have been used as operands of the same operator. The
following restrictions apply to the use of parameter markers:
v Both the operands in a predicate cannot be parameter markers. For example, specifying
predicates of the form: ? = ? or ? = ( SELECT ? FROM x ) are not valid.
v Both the operands in a expression cannot be parameter markers. For example, specifying
an expression of the form: ? + ? is not valid.
v At least one of the operands in the BETWEEN predicate cannot be a parameter marker.
For example, specifying the predicate of the form: ? BETWEEN ? and ? is not valid.
v At least, one of the operands of the IN predicate must not be a parameter marker. For
example, specifying the predicate of the form: ? IN (?, ?, ?) is not valid.
Recovery Text: Correct the statement so that all operands of the predicate or expression are not parameter
markers. A CAST specification can be used in most cases to assign attributes to a parameter
marker. Try the request again.
SQLCODE or -417
SQLCODEs:
SQLSTATE or 42609
SQLSTATEs:
SQL0418
Message Text: Use of parameter marker not valid.
SQL0419
Message Text: Negative scale not valid.
Cause Text: A decimal division operation has produced a negative scale. To view the algorithm used to
determine the scale for decimal division, refer to the DB2 UDB for iSeries SQL Reference
topic in the Information Center, http://www.ibm.com/eserver/iseries/infocenter.
Recovery Text: Change one of the operands to floating point by using the FLOAT scalar function. This will
change the result of division to floating point. If a decimal result is desired, use the
DECIMAL scalar function in the floating point result. If one of the operands is integer,
small integer, or big integer, SQL has converted it to decimal prior to the division. The
DECIMAL function can be used to explicitly convert the integer, small integer, or big
integer to a precision that will not cause the division to produce a negative scale. Try the
request again.
SQLCODE or -419
SQLCODEs:
SQLSTATE or 42911
SQLSTATEs:
SQL0420
Message Text: Character in CAST argument not valid.
Cause Text: A character in the argument for the CAST function was not correct.
Recovery Text: Change the result data type to one that recognizes the characters in the CAST argument, or
change the argument to contain a valid representation of a value for the result data type.
Try the request again.
SQLCODE or +420, -420
SQLCODEs:
SQL0421
Message Text: Number of columns not consistent.
Cause Text: The subselects of a UNION, INTERCEPT, or EXCEPT must have the same number of result
columns. All rows specified for a multiple row insert must have the same number of
values.
Recovery Text: Correct the SQL statement so that the same number of columns are defined for each row.
Try the request again.
SQLCODE or -421
SQLCODEs:
SQLSTATE or 42826
SQLSTATEs:
SQL0423
Message Text: LOB locator &1 not valid.
Cause Text: The value of locator &1 is not currently valid. The locator may have been freed by a
previous FREE LOCATOR statement or a COMMIT or ROLLBACK.
Recovery Text: Ensure that the locator value refers to an active locator that has not been freed because of a
FREE LOCATOR, COMMIT, or ROLLBACK statement. A LOB value can be assigned to a
locator variable by means of a SELECT INTO statement, a VALUES INTO or SET statement,
or a FETCH statement.
SQLCODE or -423
SQLCODEs:
SQLSTATE or 0F001
SQLSTATEs:
SQL0426
Message Text: Dynamic COMMIT is not valid for the application environment.
Cause Text: An application using DRDA two-phase commit protocols has attempted to issue a dynamic
COMMIT, or has called a stored procedure which performed a COMMIT ON RETURN.
Recovery Text: Remove the dynamic COMMIT statement, or change the stored procedure definition to not
use COMMIT ON RETURN.
SQLCODE or -426
SQLCODEs:
SQLSTATE or 2D528
SQLSTATEs:
SQL0427
Message Text: Dynamic ROLLBACK is not valid for the application environment.
Cause Text: An application using DRDA two-phase commit protocols has attempted to issue a dynamic
ROLLBACK.
Recovery Text: Remove the dynamic ROLLBACK statement.
SQLCODE or -427
SQLCODEs:
SQL0428
Message Text: SQL statement cannot be run.
Cause Text: The statement cannot be run in the current application state. A SET TRANSACTION,
DISCONNECT, or SET SESSION AUTHORIZATION statement was encountered and a
connection is not at a commit boundary. A SET SESSION AUTHORIZATION statement was
encountered and one of the following has occurred:
v The SYSTEM_USER is one of the system-supplied user profiles such as QSYS,
QDFTOWN, or QSPL.
v The current server is a local relational database and there is an active connection to a
remote relational database.
v A stored procedure, user-defined function, or trigger is running.
v Resources are being held because a COMMIT HOLD or HOLD LOCATOR statement has
been run.
v The maximum number of ProfileHandles have been generated.
Recovery Text: Do one of the following actions prior to running the SQL statement. Try the request again.
v If the connection is not at a commit boundary, issue a COMMIT or ROLLBACK SQL
statement.
v If connections to remote relational databases are active, disconnect the remote
connections.
v If the SYSTEM_USER is one of the system-supplied user profiles, sign-on with a
different user profile.
v If resources are being held because a COMMIT HOLD has been run, issue a COMMIT or
ROLLBACK SQL statement.
v If resources are being held because a HOLD LOCATOR has been run, issue a
ROLLBACK or FREE LOCATOR SQL statement.
v If the maximum number of ProfileHandles have been generated, release some of the
ProfileHandles that are no longer needed using the Release ProfileHandle (QSYRLSPH)
program.
SQLCODE or -428
SQLCODEs:
SQLSTATE or 25501
SQLSTATEs:
SQL0429
Message Text: The maximum number of concurrent LOB locators has been reached.
Cause Text: The LOB locator could not be generated because there are already 16000000 valid locators
for this process.
Recovery Text: Use the FREE LOCATOR statement to free LOB locators.
SQLCODE or -429
SQLCODEs:
SQLSTATE or 54028
SQLSTATEs:
SQL0432
Message Text: A parameter marker cannot have the user-defined type name &1.
SQL0433
Message Text: Significant data truncated during CAST to character.
Cause Text: The length of the resulting character string is not large enough to hold the character
representation of the value.
Recovery Text: Change the result data type to a character string long enough to hold the result. Try the
request again.
SQLCODE or -433
SQLCODEs:
SQLSTATE or 22001
SQLSTATEs:
SQL0435
Message Text: SQLSTATE value &1 not valid.
Cause Text: SQLSTATE value &1 specified in a handler or condition, in a SIGNAL or RESIGNAL
statement, or in a RAISE_ERROR function is not valid. SQLSTATE values must have a
length of 5 and must contain uppercase characters A-Z or numbers 0-9. The first two
characters of the SQLSTATE value cannot be ’00’. The SQLSTATE value in a RAISE_ERROR
function cannot begin with ’00’, ’01’, or ’02’. If the SQLSTATE value shown is ’*N’, an
empty string or null value was passed for the SQLSTATE.
Recovery Text: Change the SQLSTATE to one that is valid. Try the request again.
SQLCODE or -435
SQLCODEs:
SQLSTATE or 428B3
SQLSTATEs:
|| SQL0438
| Message Text: Message &1 returned from SIGNAL, RESIGNAL, or RAISE_ERROR.
| Cause Text: An application has executed a SIGNAL or RESIGNAL statement or has invoked the
| RAISE_ERROR function. If the application is an SQL procedure, function, or trigger, the
| SQLSTATE was not handled in the SQL routine. The message returned is &1.
| Recovery Text: See the documentation for the application that issued the SIGNAL or RESIGNAL statement
| or invoked the RAISE_ERROR function.
| SQLCODE or +438, -438
| SQLCODEs:
| SQLSTATE or Application defined
| SQLSTATEs:
SQL0440
Message Text: Routine &1 in &2 not found with specified parameters.
Cause Text: A function or procedure with the specified name and compatible arguments was not found.
Recovery Text: Specify the correct number and type of parameters on the CALL statement or function
invocation. Try the request again.
SQLCODE or -440
SQLCODEs:
SQLSTATE or 42884
SQLSTATEs:
SQL0441
Message Text: Clause or keyword &1 not valid where specified.
Cause Text: One of the following errors has occurred:
v AS LOCATOR is specified for a parameter in a procedure or as a parameter or in the
returns clause of a function and the parameter is not defined as BLOB, CLOB, or
DBCLOB. If the parameter is defined as BLOB, CLOB, or DBCLOB, a length, a CCSID
value, or a FOR BIT DATA, FOR MIXED DATA, or FOR SBCS DATA clause was
specified.
v ALL or DISTINCT is specified in a function that is not a column function.
Recovery Text: Specify the type as BLOB, CLOB, or DBCLOB or remove the AS LOCATOR clause. Remove
the ALL or DISTINCT keyword from the function.
SQLCODE or -441
SQLCODEs:
SQLSTATE or 42601
SQLSTATEs:
SQL0442
Message Text: Too many parameters for procedure &1 in &2 on CALL statement.
Cause Text: Only 1024 parameters are allowed on the CALL statement. If the procedure is a REXX
procedure, only 32766 bytes of data can be passed on the CALL statement.
Recovery Text: Reduce the number of parameters specified to the maximum of 1024. If calling a REXX
procedure, limit the total number of bytes of parameter data to be less than 32766. Try the
request again.
SQLCODE or -442
SQLCODEs:
SQLSTATE or 54023
SQLSTATEs:
SQL0443
Message Text: Trigger program or external routine detected an error.
Cause Text: Either a trigger program, external procedure, or external function detected and returned an
error to SQL. If the error occurred in a trigger program, the trigger was on table &4 in
schema &5. If the error occurred in an external procedure or function, the external name is
&4 in schema &5. The associated text is &6. If the error occurred in a trigger program, the
associated text is the type of trigger program. If the error occurred in an external function,
the associated text is the text of the error message returned from the external function.
SQL0444
Message Text: External program &4 in &5 not found.
Cause Text: An attempt was made to CALL procedure or invoke function &1 in &2. External program
or service program &4 in schema &5 was not found.
Recovery Text: The external program or service program associated with the procedure or function cannot
be found. Ensure that an object exists with the name specified on the DECLARE
PROCEDURE, CREATE PROCEDURE, or CREATE FUNCTION statement. If no name was
specified, ensure that an object with a name which matches the procedure or function name
specified exists. If a program name was specified, a program object must exist. If an entry
point name was specified, then a service program object must exist. Try the request again.
SQLCODE or -444
SQLCODEs:
SQLSTATE or 42724
SQLSTATEs:
SQL0445
Message Text: Value of parameter &4 in procedure &1 in &2 too long.
Cause Text: Parameter &4, which is declared as OUT or INOUT, contains a value that is longer than the
maximum length string that can be stored in host variable &8. Parameter &4 is being
returned from procedure &1 in &2 to host variable &8. Trailing blanks are not included in
the length of the string for character values. Trailing hex zeros are not included in the
length of the string for binary values. The length of the parameter is &6 and the length of
the host variable is &7.
Recovery Text: Increase the length of the host variable from &7 to &6. Try the request again.
SQLCODE or +445
SQLCODEs:
SQLSTATE or 01004
SQLSTATEs:
SQL0446
Message Text: Conversion error in assignment of argument &2.
Cause Text: During an attempt to assign input argument number &1 on a CALL statement to the
corresponding parameter for the call, error type &3 occurred. A list of the error types
follows:
v 1 - Overflow.
v 2 - Floating point overflow.
v 3 - Floating point underflow.
v 4 - Floating point conversion error.
v 5 - Not an exact result.
v 6 - Numeric data that is not valid.
v 7 - Double-byte character set (DBCS) data that is not valid. The parameter name is &2.
SQL0448
Message Text: Too many parameters or result sets for routine &1 in &2.
Cause Text: One of the following limits has been exceeded:
v 1024 parameters in a DECLARE PROCEDURE, CREATE PROCEDURE, or ALTER
PROCEDURE statement. The actual number may be less and depends on the language.
v 1023 parameters if GENERAL WITH NULLS is specified.
v 90 parameters if PARAMETER STYLE SQL or DB2SQL is specified.
v 1024 parameters for an SQL procedure.
v 90 parameters in a CREATE FUNCTION statement.
v 124 parameters and return values in a CREATE FUNCTION(Table) statement.
v 255 for languages other than C and C++.
v 32767 result sets.
Recovery Text: Reduce the number of parameters defined to the maximum or change the value for the
number of result sets to be less than or equal to 32767. Try the request again.
SQLCODE or -448
SQLCODEs:
SQLSTATE or 54023
SQLSTATEs:
SQL0449
Message Text: External program name for routine &1 in &2 not valid.
Cause Text: The external program name specified on a DECLARE PROCEDURE, CREATE
PROCEDURE, or CREATE FUNCTION statement is not valid for the routine or the
language specified.
v The external program name for a procedure or function must be of the form
’library-name/program-name’ or ’library-name/program-name(entry-point-name)’.
v The external program name for a JAVA procedure or function must be
’class-name!method-name’ or ’class-name.method-name’.
v The external program name for a REXX procedure must be ’library-name/source-file-
name(member-name)’.
Recovery Text: Specify the correct form of the external program name. Try the request again.
SQLCODE or -449
SQLCODEs:
SQLSTATE or 42878
SQLSTATEs:
SQL0451
Message Text: Attributes of parameter &1 not valid for procedure or function &3 in &4.
SQL0452
Message Text: Unable to access a file that is referred to by a file reference variable.
Cause Text: The file referred to by the file reference variable (host variable &1) could not be accessed
because of reason code &2. The reason codes and their meanings are:
v 1 - The file name or path has a format that is not valid.
v 2 - The length of the file name is greater than the maximum allowed length.
v 3 - The file option is not valid.
v 4 - The file or directory cannot be found.
v 5 - A file already exists with the same name as that specified for a file that has the NEW
option.
Recovery Text: Do one of the following:
v If the reason code is 1, correct the format of the filename or path and then try the request
again.
v If the reason code is 2, correct the file name and then try the request again.
v If the reason code is 3, correct the file option and then try the request again.
v If the reason code is 4, specify SQL_FILE_CREATE for the file option, or verify the
directory exists, and then try the request again.
v If the reason code is 5, specify SQL_FILE_OVERWRITE or SQL_FILE_APPEND and then
try the request again.
SQLCODE or -452
SQLCODEs:
SQL0453
Message Text: Return type for function &1 in &2 not compatible with CAST TO type.
Cause Text: The data types specified in the RETURNS clause for function &1 in &2 are not valid. The
CAST TO and CAST FROM data types are not compatible.
Recovery Text: Correct the data type specified in the RETURNS clause for the function. Try the request
again.
SQLCODE or -453
SQLCODEs:
SQLSTATE or 42880
SQLSTATEs:
SQL0454
Message Text: Routine &1 in &2 already exists.
Cause Text: One of the following has occurred:
v Procedure &1 with the same number of parameters already exists in schema &2.
Procedures in a schema cannot have the same name and number of parameters.
v Function &1 with the same signature already exists in schema &2. All functions in the
same schema must have a unique signature. The database uses the name of the function
and the number and data types of the arguments to determine the signature for the
function.
Recovery Text: Change the routine name or the parameters or drop the existing routine. Try the request
again.
SQLCODE or -454
SQLCODEs:
SQLSTATE or 42723
SQLSTATEs:
SQL0455
Message Text: Schema &2 for specific name not same as routine schema &3.
Cause Text: The specific name schema &2 specified on a CREATE PROCEDURE, DECLARE
PROCEDURE, ALTER PROCEDURE, or CREATE FUNCTION statement is not the same as
schema &3 for procedure or function &1.
Recovery Text: Specify the same schema for the specific name as for the procedure or function name.
SQLCODE or -455
SQLCODEs:
SQLSTATE or 42882
SQLSTATEs:
SQL0456
Message Text: Specific name &3 in &2 already exists.
Cause Text: An attempt was made to create a function or procedure &1 in &2 with specific name &3,
but specific name &3 already exists in the schema. All routines (functions and procedures)
in the same schema must have unique specific names.
SQL0457
Message Text: Name &1 in &2 not allowed for function.
Cause Text: Function &1 in &2 cannot be created or cannot be used as the source function name. Either
the function name is a reserved word or the schema is specified as QSYS, QSYS2, SYSIBM,
or QTEMP. Functions cannot be created in QSYS, QSYS2, SYSIBM, or QTEMP.
Recovery Text: Change the name of the function to one that is not reserved or specify a different schema.
Try the request again.
SQLCODE or -457
SQLCODEs:
SQLSTATE or 42939
SQLSTATEs:
SQL0458
Message Text: Function &1 in &2 not found with matching signature.
Cause Text: Function &1 is specified in schema &2. The name of the function and the number and data
types of the parameters make up the function signature. A function with a matching
signature was not found.
Recovery Text: Ensure that the function name specified exists and that the number and data types of the
parameters match those in the function definition. Try the request again.
SQLCODE or -458
SQLCODEs:
SQLSTATE or 42883
SQLSTATEs:
SQL0460
Message Text: Truncation of data may have occurred for ALTER TABLE of &1 in &2.
Cause Text: Table &1 in &2 has been altered. The length of column &3 has been reduced and data may
have been truncated.
Recovery Text: No recovery is necessary.
SQLCODE or +460
SQLCODEs:
SQLSTATE or 01593
SQLSTATEs:
SQL0461
Message Text: CAST from &1 to &2 not supported.
Cause Text: CAST is not supported from data type &1 to data type &2. If the CAST is from date, time,
or timestamp to character, the length of the character result is too small.
SQL0462
Message Text: Procedure or user defined function &1 in &2 returned a warning SQLSTATE.
Cause Text: An SQLSTATE of the form 01Hxx was returned by the procedure or user defined function
&1 in &2 (with specific name &3), along with message text &4.
Recovery Text: The user must understand the meaning of the warning. See your database administrator, or
the author of the UDF or procedure.
SQLCODE or +462
SQLCODEs:
SQLSTATE or 01Hxx
SQLSTATEs:
SQL0464
Message Text: Procedure &1 returned &3 result sets, which exceeds the defined limit of &4.
Cause Text: The stored procedure &1 in &2 was successful. However, the stored procedure exceeded the
defined limit on the number of result sets that can be returned. Only &4 result sets are
returned to the SQL program that issued the SQL CALL statement. The possible causes are:
v The number of result sets is greater than the maximum specified when the procedure
was created.
v The stored procedure is unable to return &3 result sets due to DRDA limitations imposed
by the client.
Recovery Text: The SQL statement is successful. The SQLWARN9 field of the SQLCA is set to ’Z’.
SQLCODE or +464
SQLCODEs:
SQLSTATE or 0100E
SQLSTATEs:
SQL0466
Message Text: &3 result sets are available from procedure &1 in &2.
Cause Text: Procedure &1 in &2 was called and has returned one or more result sets.
Recovery Text: None.
SQLCODE or +466
SQLCODEs:
SQLSTATE or 0100C
SQLSTATEs:
SQL0467
Message Text: Another result set exists for procedure &1 in &2.
Cause Text: A result set was closed for &1 in &2. Another result set exists for the stored procedure. A
maximum of &3 result sets are possible for this procedure.
SQL0469
Message Text: IN, OUT, or INOUT not valid for parameter &4 in procedure &1 in &2.
Cause Text: The IN, INOUT, or OUT attribute specified for parameter &4 when the procedure was
defined is not valid. The parameter name is &5. One of the following errors occurred:
v The attribute is not consistent with the parameter on the CALL statement. If the
parameter was declared INOUT or OUT, the parameter on the CALL statement must be
specified as a host variable.
v The attribute was specified as INOUT or OUT and REXX was specified as the language.
The attribute must be IN if REXX is specified.
Recovery Text: Either change the attribute of the parameter on the DECLARE PROCEDURE, CREATE
PROCEDURE, or ALTER PROCEDURE statement or change the parameter. Try the request
again.
SQLCODE or -469
SQLCODEs:
SQLSTATE or 42886
SQLSTATEs:
SQL0470
Message Text: Null values not allowed for parameter &4 in procedure &1 in &2.
Cause Text: Null values are not allowed on the CALL statement for procedure &1 because the
procedure was declared with GENERAL specified. The null value was specified as either
the NULL keyword or a host variable with an associated indicator variable that contains a
negative value. The parameter number is &4 and the parameter name is &5.
Recovery Text: Specify PARAMETER STYLE SQL, DB2SQL, or GENERAL WITH NULLS on the CREATE
PROCEDURE or DECLARE PROCEDURE statement or pass a value other than the null
value on the CALL statement. Try the request again.
SQLCODE or -470
SQLCODEs:
SQLSTATE or 39004
SQLSTATEs:
SQL0473
Message Text: Name &1 cannot be used for user-defined type.
Cause Text: Name &1 specified for a user-defined type is the same as a system predefined type or is a
function name that is reserved. Function names that cannot be used include CAST,
DATAPARTITIONNAME, DATAPARTITIONNUM, DBPARTITIONNAME,
DBPARTITIONNUM, EXTRACT, NODENAME, NODENUMBER, PARTITION, POSITION,
RRN, STRIP, SUBSTRING, and TRIM.
Recovery Text: Change the name for the user-defined type. Try the request again.
SQLCODE or -473
SQLCODEs:
SQL0475
Message Text: RETURNS data type for function &3 in &4 not valid.
Cause Text: The data type specified for the RETURNS clause or the CAST FROM clause for function &3
in schema &4 is not appropriate for the data type returned from the sourced function or the
value specified on the RETURN statement in the SQL function body. The data type
specified in the RETURNS clause is &1 and the data type returned from the sourced
function or SQL function is &2.
Recovery Text: Correct the data types specified or specify another sourced function. Try the request again.
SQLCODE or -475
SQLCODEs:
SQLSTATE or 42866
SQLSTATEs:
SQL0476
Message Text: Routine &1 in &2 not unique.
Cause Text: Function or procedure &1 in &2 was specified, not by signature or specific name, and more
than one specific instance of the routine was found.
Recovery Text: Request the routine either by its specific name, or by its signature (function or procedure
name with parameter types). Try the request again.
SQLCODE or -476
SQLCODEs:
SQLSTATE or 42725
SQLSTATEs:
SQL0478
Message Text: Object &1 in &2 of type &3 cannot be dropped.
Cause Text: The base object &1 cannot be dropped because another object depends on it. The dependent
object &4 in &5 is of type &6.
v If base object type is *N, the object being dropped is a function. When dropping a
function, the dependent object is sourced on the base object. For objects other than
functions, it may be that the dependency is indirect. That is, the named object is
dependent on another object which is dependent on the object being dropped.
v If the base object is a table and if there are other tables with triggers or foreign key
constraints dependent on the base table, then the RESTRICT clause of the DROP
statement will prevent the base table from being dropped.
v If the base object is *LIB and if there are tables, views, functions, procedures, distinct
types, aliases, or triggers in the schema, then the RESTRICT clause of the DROP
statement will prevent the schema from being dropped. A trigger can be defined in one
schema on a table that exists in a different schema.
v If the base object is *SQLUDT and if there are tables, views, indexes, functions,
procedures, sequences, or triggers dependent on the distinct type, then the RESTRICT
clause of the DROP statement will prevent the base distinct type from being dropped.
Recovery Text: Drop the dependent objects first. Try the request again.
SQLCODE or -478
SQLCODEs:
SQL0483
Message Text: Parameters for function &1 in &2 not same as sourced function.
Cause Text: The number of parameters specified for function &1 in &2 is not the same as the number of
parameters specified for the sourced function.
Recovery Text: Specify the correct number of parameters for the function or specify another sourced
function. If not qualified, ensure the correct sourced function exists in the current path. Try
the request again.
SQLCODE or -483
SQLCODEs:
SQLSTATE or 42885
SQLSTATEs:
SQL0484
Message Text: Routine &1 in &2 already exists.
Cause Text: An attempt was made to create routine &1 in &2, but &1 already exists. All procedures and
functions in the same schema must have unique specific names.
Recovery Text: Specify a SPECIFIC name that does not exist or do not specify a SPECIFIC name and a
unique name will be generated for you. Otherwise, delete the existing routine. Try the
request again.
SQLCODE or -484
SQLCODEs:
SQLSTATE or 42733
SQLSTATEs:
SQL0487
Message Text: SQL statements not allowed.
Cause Text: One of the following errors has occurred:
v A procedure was called or a function was invoked that was created with NO SQL
specified as the data access attribute. A routine created with NO SQL, or any subsequent
routines, cannot contain SQL statements and cannot invoke a routine that has the
CONTAINS SQL DATA, READS SQL DATA, or MODIFIES SQL DATA attribute.
v NO SQL cannot be specified when creating an SQL procedure or function.
v A trigger containing SQL statements was activated. If the error occurred in a procedure
or function, the routine name is &1 and the specific name is &2.
Recovery Text: Ensure routines created as NO SQL only invoke routines that do not contain SQL
statements. Do not specify NO SQL for an SQL procedure or function.
SQLCODE or -487
SQLCODEs:
SQLSTATE or 38001
SQLSTATEs:
SQL0490
Message Text: Numeric value &1 not valid.
SQL0491
Message Text: Clause not correct for CREATE FUNCTION or CREATE PROCEDURE.
Cause Text: A clause for CREATE PROCEDURE or CREATE FUNCTION is missing or not allowed. The
reason code is &1. Reason codes and their meanings are:
v 1 - For CREATE FUNCTION, the RETURNS clause is required.
v 2 - For CREATE FUNCTION, the DBINFO, FINAL CALL, and SCRATCHPAD clauses
cannot be specified if the parameter style is SQL or GENERAL. For CREATE
PROCEDURE, DBINFO cannot be specified unless the parameter style is DB2SQL.
v 3 - For CREATE FUNCTION, GENERAL can only be specified if the EXTERNAL NAME
specifies a service program.
v 4 - For CREATE PROCEDURE and CREATE FUNCTION, parameter style JAVA or
DB2GENERAL can only be specified for LANGUAGE JAVA.
v 5 - For CREATE FUNCTION, a table function cannot have parameter style SQL, JAVA,
GENERAL, or GENERAL WITH NULLS.
v 6 - For CREATE PROCEDURE and CREATE FUNCTION, PROGRAM TYPE MAIN is not
allowed for JAVA or REXX. For CREATE FUNCTION, PROGRAM TYPE SUB is only
allowed for service programs.
v 7 - For CREATE FUNCTION, a table function must specify DISALLOW PARALLEL.
v 8 - The CARDINALITY clause is only allowed for table functions.
Recovery Text: Add the missing clause or remove the clause that is not allowed. Try the request again.
SQLCODE or -491
SQLCODEs:
SQLSTATE or 42601
SQLSTATEs:
SQL0492
Message Text: Data type for function &1 in &2 not valid for source type.
Cause Text: The data type specified for parameter &3 for function &1 in library &2 is not valid for the
corresponding type of the SOURCE function.
Recovery Text: Correct the data type specified for parameter &3 or specify another sourced function. Try
the request again.
SQLCODE or -492
SQLCODEs:
SQLSTATE or 42879
SQLSTATEs:
SQL0501
Message Text: Cursor &1 not open.
SQL0502
Message Text: Cursor &1 already open.
Cause Text: The cursor specified in an OPEN statement is already open for this call of the program.
Recovery Text: Close cursor &1 and then try the OPEN statement again or change the name of the cursor,
and then precompile the program again.
SQLCODE or -502
SQLCODEs:
SQLSTATE or 24502
SQLSTATEs:
SQL0503
Message Text: Column &3 cannot be updated.
Cause Text: An UPDATE statement attempted to update column &3 in table or view &1 in &2. The
column cannot be updated because it was not specified in the FOR UPDATE OF clause in
the associated DECLARE CURSOR statement.
Recovery Text: Add column &3 to the FOR UPDATE OF clause in the related DECLARE CURSOR
statement. Precompile the program again.
SQLCODE or -503
SQLCODEs:
SQLSTATE or 42912
SQLSTATEs:
SQL0507
Message Text: Cursor &1 not open.
Cause Text: Cursor &1 was specified in an UPDATE or DELETE statement, but the cursor is not open.
Cursor &1 has one of the following conditions:
v Cursor &1 was never opened.
v The cursor &1 was opened in another program or another call of this program and the
program was created with CLOSQLCSR(*ENDPGM).
v The cursor &1 was opened in another module or another call of this module and the
module was created with CLOSQLCSR(*ENDMOD).
v The cursor &1 was opened in another call of this program and programs which have
run SQL statements have ended and the program was created with
CLOSQLCSR(*ENDSQL).
v The cursor &1 was opened in another call of this module and the activation group was
ended between calls. The program was created with CLOSQLCSR(*ENDACTGRP).
v The cursor was closed by a CLOSE, COMMIT, or ROLLBACK statement.
Recovery Text: Do one of the following and precompile again:
v Make certain that cursor &1 is opened in the same program or module call prior to using
the cursor in an UPDATE or DELETE statement.
v Specify either CLOSQLCSR(*ENDSQL), CLOSQLCSR(*ENDJOB), or
CLOSQLCSR(*ENDACTGRP) when precompiling the application.
v If the cursor was closed by a COMMIT or ROLLBACK, specify HOLD on the COMMIT
or ROLLBACK statement to preserve any open cursors, prepared statements, and locks
on tables.
SQLCODE or -507
SQLCODEs:
SQLSTATE or 24501
SQLSTATEs:
SQL0508
Message Text: Cursor &1 not positioned on locked row.
Cause Text: An UPDATE or DELETE statement with a WHERE CURRENT OF &1 was attempted, but
the cursor is not positioned on a row or is positioned on a row, but the row is not locked
because a COMMIT HOLD or ROLLBACK HOLD statement released the lock on the row.
A FETCH statement must be issued to position the cursor on a row and lock the row.
SQL0509
Message Text: Table &2 in &3 not same as table in cursor &1.
Cause Text: An UPDATE or DELETE statement with a WHERE CURRENT OF &1 specified the table
&2 in &3, but cursor &1 refers to a different table. The table specified in the UPDATE or
DELETE statement and the table referred to by cursor &1 must be the same.
Recovery Text: Change the specified table name to match the table specified in the cursor &1 and
precompile the program again.
SQLCODE or -509
SQLCODEs:
SQLSTATE or 42827
SQLSTATEs:
SQL0510
Message Text: Cursor &1 for table &2 read-only.
Cause Text: An UPDATE or DELETE statement with a WHERE CURRENT OF clause was specified, but
the cursor is read only. Either the cursor &1 is read-only or the view &2 in schema &3 is
read-only. A view or logical file is read-only if one or more of the following conditions are
true:
v The view contains a DISTINCT keyword, GROUP BY clause, HAVING clause, a column
function, or UNION, EXCEPT, or INTERSECT in the outer-most subselect.
v The view or logical file contains a join function.
v The view contains a subquery that refers to the same table as the table of the outer-most
subselect.
v All the columns of the view are expressions, scalar functions, or constants.
v All the columns of the logical file are input only.
A cursor is read-only if one or more of the following conditions is true:
v The DECLARE CURSOR statement specified an ORDER BY clause but did not specify a
FOR UPDATE OF clause.
v The DECLARE CURSOR statement specified a FOR READ ONLY clause.
v The DECLARE CURSOR statement specified the SCROLL keyword without DYNAMIC.
v The cursor referred to a read-only view or logical file in the select list.
v The subselect specified in the DECLARE CURSOR statement contains any of the above
restrictions that would make a view read only.
v A second INSTEAD OF trigger is required for the update or delete on a dependent view.
SQL0511
Message Text: FOR UPDATE clause not valid.
Cause Text: The FOR UPDATE clause cannot be used for cursor &1 because the result table is read only.
The result table is read only if:
v The first SELECT clause of the statement includes the DISTINCT keyword, a column
function, a GROUP BY clause, a HAVING clause, or a UNION, EXCEPT, or INTERSECT
operator.
v The first FROM clause of the SELECT statement identifies more than one table, more
than one view, or a read-only view.
Recovery Text: Cursor &1 cannot be updated. Remove the FOR UPDATE clause.
SQLCODE or -511
SQLCODEs:
SQLSTATE or 42829
SQLSTATEs:
SQL0513
Message Text: Alias &1 in &2 cannot reference another alias.
Cause Text: Alias &1 in &2 can only reference a table or a view. It cannot reference another alias.
Recovery Text: Change the referenced name and try the request again.
SQLCODE or -513
SQLCODEs:
SQLSTATE or 42924
SQLSTATEs:
SQL0514
Message Text: Prepared statement &2 not found.
SQL0516
Message Text: Prepared statement &2 not found.
Cause Text: &2 is not a valid prepared statement. The statement has one of the following conditions:
v The statement has never been prepared.
v The statement was prepared in another program or another call of this program and the
program was created with CLOSQLCSR(*ENDPGM).
v The statement was prepared in another module or another call of this module and the
module was created with CLOSQLCSR(*ENDMOD).
v The statement was prepared in another call of this program and programs which have
run SQL statements have ended and the program was created with
CLOSQLCSR(*ENDSQL).
v The statement was prepared in another call of this module and the activation group
ended between calls. The module was created with CLOSQLCSR(*ENDACTGRP).
v A COMMIT or ROLLBACK statement has destroyed all the prepared statements.
Recovery Text: Do one of the following and precompile again:
v Make certain that &1 has been prepared in the same program or module call prior to
using the DESCRIBE statement or specify either CLOSQLCSR(*ENDSQL),
CLOSQLCSR(*ENDJOB), or CLOSQLCSR(*ENDACTGRP) when precompiling the
application.
v If the statement was deleted by a COMMIT or ROLLBACK, specify HOLD on the
COMMIT or ROLLBACK statement to preserve any open cursors, prepared statements,
and locks on tables.
SQL0517
Message Text: Prepared statement &2 not SELECT statement.
Cause Text: An attempt was made to open cursor &1, which refers to statement &2. Statement &2 is a
valid prepared statement, but it is not a SELECT statement. OPEN can only refer to
prepared SELECT statements.
Recovery Text: Change the OPEN statement to refer to a prepared SELECT statement, or prepare statement
&2 using a valid SELECT statement and then try the open.
SQLCODE or -517
SQLCODEs:
SQLSTATE or 07005
SQLSTATEs:
SQL0518
Message Text: Prepared statement &1 not found.
Cause Text: An EXECUTE statement referred to the statement &1. &1 is not a valid prepared statement.
The statement has one of the following conditions:
v The statement has never been prepared.
v The statement identifies a prepared SELECT or DECLARE PROCEDURE statement.
v The statement was in error at prepare or bind time.
v The statement was prepared in another program or another call of this program and the
program was created with CLOSQLCSR(*ENDPGM).
v The statement was prepared in another module or another call of this module and the
module was created with CLOSQLCSR(*ENDMOD).
v The statement was prepared in another call of this program and programs which have
run SQL statements have ended and the program was created with
CLOSQLCSR(*ENDSQL).
v The statement was prepared in another call of this module and the activation group
ended between calls. The module was created with CLOSQLCSR(*ENDACTGRP).
v The prepared statement was destroyed by a COMMIT or ROLLBACK statement. This
only occurs when connected to a database other than DB2 UDB for iSeries.
Recovery Text: Do one of the following:
v If &1 identifies a prepared SELECT or DECLARE PROCEDURE statement, a different
prepared statement must be named in the EXECUTE statement.
v If the statement had errors, correct the errors and either prepare the statement again or
precompile the program again.
v Make certain that &1 has been prepared in the same program or module call prior to
using the EXECUTE statement or specify either CLOSQLCSR(*ENDSQL),
CLOSQLCSR(*ENDJOB), or CLOSQLCSR(*ENDACTGRP) when precompiling the
application.
v If the statement was deleted by a COMMIT or ROLLBACK, either specify PREPARE
WITH HOLD or bind the program with the correct option to preserve prepared
statements.
SQLCODE or -518
SQLCODEs:
SQL0519
Message Text: Prepared statement &2 in use.
Cause Text: The application program has attempted to prepare statement &2. This statement is the
SELECT statement for cursor &1 that is currently open.
Recovery Text: Change the statement name in the PREPARE statement or correct the logic of the
application program so that it closes cursor &1 before attempting the PREPARE statement
again.
SQLCODE or -519
SQLCODEs:
SQLSTATE or 24506
SQLSTATEs:
SQL0520
Message Text: Cannot UPDATE or DELETE on cursor &1.
Cause Text: Cursor &1 is blocking records. An UPDATE or DELETE WHERE CURRENT OF cursor &1
was attempted but cannot be run because blocking was being used for the cursor.
Recovery Text: Do not block records for cursor &1 if UPDATE or DELETE statements will be used against
it.
SQLCODE or -520
SQLCODEs:
SQLSTATE or 42828
SQLSTATEs:
SQL0525
Message Text: Statement not valid on application server.
Cause Text: An attempt was made to run statement number &4 of package &2 in schema &3. Either the
statement is in error, or the statement is not supported by the application server. The
section number corresponding to the statement is &1.
Recovery Text: Correct the statement which is in error and verify that it is a valid SQL statement on the
application server. If the statement is a multiple-row FETCH, specify a single-row FETCH.
If the statement is a multiple-row INSERT, either specify a VALUES clause with one or
more rows to insert, or specify a subselect. If the statement is SET TRANSACTION, remove
it from the application or prevent it from being issued when the Distributed Relational
Database Architecture (DRDA) connection is used. Try the request again.
SQLCODE or -525
SQLCODEs:
SQLSTATE or 51015
SQLSTATEs:
SQL0526
Message Text: Statement not valid for &1 TEMPORARY TABLE &2 in &3.
SQL0527
Message Text: ALWCPYDTA(*NO) specified but temporary result required for &1.
Cause Text: The Allow Copy Data (ALWCPYDTA) parameter was specified on the precompiler
command or the STRSQL command with a value of *NO. This value indicates that the
queries should always use data directly retrieved from the database, so that the data always
reflects the current values. Certain types of SQL queries can not be resolved without
making a copy of the data. Examples would be queries using the keywords DISTINCT or
UNION. The query being run is a query which requires a copy of the data.
Recovery Text: Specify a different value for the ALWCPYDTA parameter or change the SQL statement so
that it can be evaluated without using a temporary result.
SQLCODE or -527
SQLCODEs:
SQLSTATE or 42874
SQLSTATEs:
SQL0530
Message Text: Operation not allowed by referential constraint &1 in &2.
Cause Text: If this is an INSERT or UPDATE statement, the value is not valid for the foreign key
because it does not have a matching value in the parent key. If this is a DELETE statement
affected by a SET DEFAULT delete rule, the default value is not valid for the same reason.
If this is an ALTER TABLE statement, the result of the operation would violate the
constraint &1. Constraint &1 in &2 for table &3 in &4 requires that any non-null value of
the foreign key have a matching value in the parent key.
Recovery Text: To conform to the constraint rule, you must either:
v change the INSERT or UPDATE value to match a value in the parent key
v insert a row in the parent file that matches the foreign key values being inserted or
updated
v insert a row in the parent file that matches the foreign key default values of the
dependent rows. Otherwise, you must drop the referential constraint.
SQLCODE or -530
SQLCODEs:
SQLSTATE or 23503
SQLSTATEs:
SQL0531
Message Text: Update prevented by referential constraint &1 in &2.
SQL0532
Message Text: Delete prevented by referential constraint &1 in &2.
Cause Text: Constraint &1 in &2 identifies the table being modified as the parent table in a relationship
with dependent table &3 in &4, with a delete rule of RESTRICT or NO ACTION. The
deletion of a row is prevented when there are rows in the dependent table with matching
values.
Recovery Text: In order to delete the row, you must either drop the constraint, or delete the rows in the
dependent table that are dependent on this row.
SQLCODE or -532
SQLCODEs:
SQLSTATE or 23001, 23504
SQLSTATEs:
SQL0536
Message Text: Delete not allowed because table &1 in &2 in subquery can be affected.
Cause Text: The delete operation can not be performed because table &1 in &2, which is referenced in a
subquery, may be affected by the operation. &1 in &2 is a dependent table in a referential
constraint that has a delete rule of CASCADE, SET NULL, or SET DEFAULT.
Recovery Text: Change the statement so that the subquery does not refer to a dependent table, or drop the
constraint that defines the relationship between the two tables.
SQLCODE or -536
SQLCODEs:
SQLSTATE or 42914
SQLSTATEs:
SQL0537
Message Text: Duplicate column name &1 in definition of key.
Cause Text: Column &1 is specified more than once in the list of columns for a primary, unique,
foreign, or partitioning key. Columns may only be specified once in the definition of a key.
Recovery Text: Remove the duplicate column from the list of columns for the key. Try the request again.
SQLCODE or -537
SQLCODEs:
SQLSTATE or 42709
SQLSTATEs:
SQL0539
Message Text: Table &1 in &2 does not have a primary or unique key.
Cause Text: Table &1 in &2 was specified either as the parent table in a referential constraint, or as the
table from which to drop the primary or unique key in an ALTER TABLE statement. When
no referencing column list is specified in a referential constraint, an attempt is made to use
the primary key of the parent table. Table &1 has no primary key defined.
Recovery Text: Correct the statement so that a referencing column list is specified in the FOREIGN KEY
clause that matches the FOREIGN KEY column list, or define a primary key for the table
being used as a parent. If this is an attempt to drop a primary or unique key, no recovery is
necessary.
SQLCODE or -539
SQLCODEs:
SQLSTATE or 42888
SQLSTATEs:
SQL0541
Message Text: Duplicate UNIQUE constraint exists for table &1 in &2.
Cause Text: An attempt was made to add UNIQUE constraint &3 in &4. Table &1 in &2 already has a
UNIQUE constraint that is a duplicate of the constraint being added. A UNIQUE constraint
is a duplicate if the columns in the constraint are the same as the columns in another
UNIQUE constraint, even if the columns are not in the same order. Constraint &1 cannot be
added.
Recovery Text: The constraint is already in effect. To change the name of the UNIQUE constraint, drop the
duplicate constraint and try the request again.
SQLCODE or -541
SQLCODEs:
SQLSTATE or 42891
SQLSTATEs:
SQL0543
Message Text: Constraint &1 conflicts with SET NULL or SET DEFAULT rule.
Cause Text: Constraint &1 is a CHECK constraint that conflicts with an existing referential constraint
that has either a SET NULL or a SET DEFAULT rule.
Recovery Text: Change the CHECK constraint so it does not conflict with the referential constraint rule, or
drop the referential constraint.
SQL0544
Message Text: CHECK constraint &1 cannot be added.
Cause Text: Existing data in the table violates the CHECK constraint rule in constraint &1. The
constraint cannot be added.
Recovery Text: Change the data in the table so that it follows the constraint specified in &1. Try the request
again.
SQLCODE or -544
SQLCODEs:
SQLSTATE or 23512
SQLSTATEs:
SQL0545
Message Text: INSERT or UPDATE not allowed by CHECK constraint.
Cause Text: The value being inserted or updated does not meet the criteria of CHECK constraint &1.
The operation is not allowed.
Recovery Text: Change the values being inserted or updated so that the CHECK constraint is met.
Otherwise, drop the CHECK constraint &1.
SQLCODE or -545
SQLCODEs:
SQLSTATE or 23513
SQLSTATEs:
SQL0546
Message Text: CHECK condition of constraint &1 not valid.
Cause Text: The CHECK condition of constraint &1 is not valid for one of the following reasons:
v a column level CHECK condition refers to some other column in the table
v the CHECK condition refers to a column that is not in this table
v the CHECK condition refers to a special register
v the CHECK condition uses a column function (such as AVG or COUNT) or a
user-defined function
v the CHECK condition contains a subselect
v the CHECK condition uses the NODENAME, DBPARTITIONNAME,
DATAPARTITIONNAME, or DATAPARTITIONNUM scalar function
v the CHECK condition uses an expression involving LOBs.
Recovery Text: Correct the error. Try the request again.
SQLCODE or -546
SQLCODEs:
SQLSTATE or 42621
SQLSTATEs:
SQL0552
Message Text: Not authorized to &1.
|| SQL0567
| Message Text: Authorization name &1 is not allowed.
| Cause Text: The authorization name cannot be a system-supplied user profile such as QSYS,
| QDFTOWN, or QSPL.
| Recovery Text: Change the name and try the request again.
| SQLCODE or -567
| SQLCODEs:
| SQLSTATE or 28000
| SQLSTATEs:
|
SQL0569
Message Text: Not all requested privileges revoked from object &1 in &2 type *&3.
Cause Text: A REVOKE operation was attempted on object &1 in &2 type *&3, but the privilege was
not revoked. Either you do not have the specified privilege to object &1, you do not have
*OBJMGT authority to object &1, or you tried to revoke the privilege from someone who
does not currently have that privilege. All valid requested privileges were revoked.
Recovery Text: If revoking a privilege from someone who does not currently have that privilege, then no
action is required. If you do not have the privilege, change the REVOKE statement to
specify valid privileges.
SQLCODE or +569
SQLCODEs:
SQLSTATE or 01006
SQLSTATEs:
SQL0570
Message Text: Not all requested privileges to object &1 in &2 type *&3 granted.
Cause Text: A GRANT operation was attempted on object &1 in &2 type *&3 but the privilege was not
granted. Either you do not have all of the privileges to be granted or you are attempting to
perform a GRANT statement using WITH GRANT OPTION but are not the object owner,
do not have *OBJMGT authority to the object, or do not have *ALLOBJ special authority.
All valid requested privileges were granted.
Recovery Text: Obtain the required authority from either the security officer or the object owner. Try the
operation again.
SQL0573
Message Text: Table &1 in &2 does not have a matching parent key.
Cause Text: A referencing column list was specified in the FOREIGN KEY clause for constraint &3 in
&4. The parent table &1 in &2 does not have a matching PRIMARY or UNIQUE key. The
constraint cannot be added.
Recovery Text: Do one of the following and try the request again:
v Specify a table in the FOREIGN KEY clause that has a PRIMARY or UNIQUE key that
matches the referencing column list.
v Change the referencing column list to match the definition of the PRIMARY or UNIQUE
key defined on the parent table.
SQLCODE or -573
SQLCODEs:
SQLSTATE or 42890
SQLSTATEs:
SQL0574
Message Text: Column or sequence attribute is not valid.
Cause Text: Either the DEFAULT value or identity attribute value for column &3 in &1 in &2 is not
valid, a sequence attribute value for sequence &1 in &2 is not valid, or an assigned value
for cycle column &3 is not valid. For a DEFAULT value, the incorrect value may either be
specified in this statement or it may already be defined for the column and is not
compatible with the attributes specified on the ALTER TABLE statement. The values must
conform to the following rules:
v The DEFAULT value must be compatible with the data type of the column. A
floating-point constant can only be a default value for a floating-point column.
v The DEFAULT value must not be too long for the column.
v If the column is defined as a date, time, or timestamp the DEFAULT value must be a
valid string representation of that type.
v If the DEFAULT value is defined as the value of the USER special register, the column
must be defined as a CHAR or VARCHAR and the length attribute must be greater than
or equal to 18.
v The CCSID of the DEFAULT value must be compatible with the CCSID of the column.
v The DEFAULT value for a column that is a user-defined type must either be promotable
to the source type or must be cast to the user-defined type using the cast function for the
type.
v A DEFAULT value cannot be specified for a DataLink column. For an identity column or
a sequence, the values specified for the START WITH, INCREMENT BY, MINVALUE,
MAXVALUE, and RESTART WITH options must have a scale of zero. For a recursive
common table expression cycle column name, the assignment value must be a character
string with a length of one.
Recovery Text: Change the value to one that is valid for the column or sequence. Try the request again.
SQLCODE or -574
SQLCODEs:
SQLSTATE or 42894
SQLSTATEs:
SQL0578
Message Text: RETURN statement not executed for SQL function &1 in &2.
Cause Text: During the execution of SQL function &1 in &2, the end of the routine body was reached
without executing a RETURN statement.
Recovery Text: Add a RETURN statement to the end of the function routine body. Try the request again.
SQLCODE or -578
SQLCODEs:
SQLSTATE or 2F005
SQLSTATEs:
SQL0579
Message Text: Reading SQL data not permitted.
Cause Text: One of the following errors has occurred:
v A procedure was called or a function was invoked that was created with CONTAINS
SQL DATA as the data access attribute. A procedure or function created with CONTAINS
SQL DATA or any procedure or function that is called by the procedure or function,
cannot read data and cannot call a procedure or function that has the READS SQL DATA
attribute.
v CONTAINS SQL DATA cannot be specified on the CREATE PROCEDURE, ALTER
PROCEDURE, or CREATE FUNCTION statements for an SQL procedure or function if
the routine body contains statements that read data.
v A trigger containing SQL statements was activated. If the error occurred in a procedure
or function, the routine name is &1 and the specific name is &2.
Recovery Text: Ensure procedures and functions created with CONTAINS SQL DATA do not call
procedures or functions that read SQL data.
SQL0580
Message Text: At least one result in CASE expression must be not NULL.
Cause Text: The NULL value, a parameter marker, or the RAISE_ERROR scalar function is specified for
all results in a CASE expression. At least one result in a CASE expression must be a value
other than NULL, a parameter marker, or the RAISE_ERROR scalar function.
Recovery Text: Change the CASE expression to have at least one result expression following a THEN or
ELSE keyword to be some value other than NULL, a parameter marker, or the
RAISE_ERROR scalar function. Try the request again.
SQLCODE or -580
SQLCODEs:
SQLSTATE or 42625
SQLSTATEs:
SQL0581
Message Text: The results in a CASE expression are not compatible.
Cause Text: The expressions specified as the result values of a CASE expression are not compatible.
Recovery Text: Change the results in the CASE expression to values that are compatible. Try the request
again.
SQLCODE or -581
SQLCODEs:
SQLSTATE or 42804
SQLSTATEs:
SQL0583
Message Text: Use of function &1 in &2 not valid.
Cause Text: Function &1 in &2 cannot be invoked where specified because it is defined to be not
deterministic or contains an external action. Functions that are not deterministic cannot be
specified in a GROUP BY clause or in a JOIN clause. Functions that are not deterministic or
contain an external action cannot be specified in a PARTITION BY clause or an ORDER BY
clause for an OLAP function. The RAISE_ERROR function cannot be specified in a GROUP
BY or HAVING clause.
Recovery Text: Remove the function. Try the request again.
SQLCODE or -583
SQLCODEs:
SQLSTATE or 42845
SQLSTATEs:
SQL0585
Message Text: Schema &1 used incorrectly in the specified path.
SQL0590
Message Text: Name &1 specified in procedure or function &2 not unique.
Cause Text: &1 is specified as a parameter, SQL variable, condition, or label in SQL procedure or
function &2. The name is not unique.
Recovery Text: Change the name so that it is unique.
SQLCODE or -590
SQLCODEs:
SQLSTATE or 42734
SQLSTATEs:
SQL0595
Message Text: Commit level *&1 escalated to *&2 lock.
Cause Text: *&1 was specified for the commit level, but *&1 was not used. The base tables were locked
*&2 to satisfy the request for commitment level of *&1. If a ROLLBACK HOLD statement is
requested, the cursor will remain in the same position. *&1 was not used for one of the
following reasons:
v A GROUP BY clause, HAVING clause, or a column function was specified in the
statement.
v A DISTINCT keyword was specified in the statement.
v A UNION keyword was specified in the statement.
v A join was specified in the statement, but not all of the files are journaled to the same
journal.
v The repeatable read commit level is implemented by DB2 UDB for iSeries by locking the
table.
Recovery Text: If escalation of commit level is not desired, change the statement or the requested commit
level. If a lock level of share-no-update (*SHRNUP) was granted, but is not acceptable,
specify *CHG or *NONE for the commit level.
SQLCODE or +595
SQLCODEs:
SQLSTATE or 01526
SQLSTATEs:
SQL0596
Message Text: Error occurred during DISCONNECT of relational database &1.
SQL0601
Message Text: &1 in &2 type &3 already exists.
Cause Text: An attempt was made to create &1 in &2 or to rename a table, view, alias, or index to &1,
but &1 already exists. All tables, views, aliases, indexes, SQL packages, sequences,
constraints, triggers, and user-defined types in the same schema must have unique names.
v If &1 is a temporary table, it cannot be replaced unless the WITH REPLACE clause is
specified.
v If the schema name is *N, this is a CREATE SCHEMA statement. If this is a CREATE
TABLE or ALTER TABLE statement and the type is *N, &1 is a constraint.
Recovery Text: Change &1 to a name that does not exist, or delete, move, or rename the existing object. If
this is a temporary table, use the WITH REPLACE clause. If creating an SQL package,
specify REPLACE(*YES) on CRTSQLPKG. Try the request again.
SQLCODE or -601
SQLCODEs:
SQLSTATE or 42710
SQLSTATEs:
SQL0602
Message Text: More than 120 columns specified for CREATE INDEX.
Cause Text: Only 120 columns are allowed in the CREATE INDEX statement.
Recovery Text: Reduce the number of column names in the column list to the maximum of 120 names. Try
the request again.
SQLCODE or -602
SQLCODEs:
SQLSTATE or 54008
SQLSTATEs:
SQL0603
Message Text: Unique index cannot be created because of duplicate keys.
Cause Text: An attempt was made to create unique index &1 in &2 or add unique constraint &1 in &2.
The operation cannot be performed because the rows in table &3 in &4 contain one or more
duplicate values in the columns used to create the index.
SQL0604
Message Text: Attributes not valid.
Cause Text: One of the following contains a length, precision, scale, or an ALLOCATE attribute that is
not valid.
v A column in the CREATE TABLE, ALTER TABLE, or DECLARE GLOBAL TEMPORARY
TABLE statement.
v A parameter or an SQL variable in the DECLARE PROCEDURE, CREATE PROCEDURE,
ALTER PROCEDURE, CREATE FUNCTION, or CREATE TRIGGER statement.
v The CAST scalar function.
v A CREATE TYPE source data type.
The definition is not valid for one of the following reasons:
v If a DECIMAL or NUMERIC data type is specified, precision must be from 1 through 63
and the scale must be between 0 and the precision.
v If CHARACTER or BINARY is specified, the length must be from 1 through 32766 for a
parameter or for a column that does not allow null values or from 1 through 32765 for a
column that allows null values.
v If VARCHAR or VARBINARY is specified, the length must be from 1 through 32740 for a
parameter or for a column that does not allow null values or from 1 through 32739 for a
column that allows null values.
v If the FOR MIXED DATA clause or a mixed CCSID is specified, the length cannot be less
than 4.
v If GRAPHIC is specified, the length must be from 1 through 16383 for a parameter or
for a column that does not allow null values and from 1 through 16382 for a column that
allows null values. The length specified is the number of DBCS characters.
v If VARGRAPHIC is specified, the length must be from 1 through 16370 for a parameter
or for a column that does not allow null values or from 1 through 16369 for a column
that allows null values. The length specified is the number of DBCS characters.
v If BLOB or CLOB is specified, the length must be from 1 through 2G (2048 M or
2,097,152 K or 2,147,483,647 bytes). If DBCLOB is specified, the length must be from 1
through 1073741823.
v If DATALINK is specified, the length must be from 1 through 32717.
v If VARCHAR, VARBINARY, CLOB, BLOB, DBCLOB, DATALINK, or VARGRAPHIC is
specified the ALLOCATE attribute must be less than or equal to both the length attribute
specified and 32766.
Recovery Text: Correct the length, precision, scale, or ALLOCATE attribute. Try the request again.
SQLCODE or -604
SQLCODEs:
SQL0607
Message Text: Operation not allowed on system table &1 in &2.
Cause Text: The table or view &1 in &2 is a catalog or system table. Catalogs, system tables and system
triggers cannot be changed or locked by the user.
Recovery Text: Change the SQL statement to refer to a table that is not a system table. Try the request
again.
SQLCODE or -607
SQLCODEs:
SQLSTATE or 42832
SQLSTATEs:
SQL0612
Message Text: &1 is a duplicate column name.
Cause Text: One of the following errors has occurred:
v Column &1 is specified more than once on a CREATE TABLE or CREATE VIEW
statement. Column names and system column names must be unique in a table or view.
v Column &1 is specified in the ADD clause of an ALTER TABLE statement. Column &1
already exists in the table.
v Column &1 is specified more than once in the ALTER, DROP, or ADD clauses of an
ALTER TABLE statement.
v Column &1 is specified more than once in the column list of a common table expression
or in the correlation clause for a table or derived table.
v Column &1 is specified more than once in the column list of an UPDATE trigger.
v Column &1 is specified more than once in the RETURNS TABLE clause of a CREATE
FUNCTION statement. The return column names for a user defined table function must
be unique.
v Column &1 is specified more than once in the CYCLE column list of the recursive
common table expression.
Recovery Text: Do one of the following and try the request again:
v Specify unique names for each of the columns.
v Remove the column from all but one clause of a single ALTER TABLE statement.
Multiple statements can be specified, if required.
SQLCODE or -612
SQLCODEs:
SQLSTATE or 42711
SQLSTATEs:
SQL0613
Message Text: Key is too long or contains too many columns.
SQL0614
Message Text: Length of columns for CREATE INDEX too long.
Cause Text: The sum of the lengths of the columns specified in a CREATE INDEX exceeds the
maximum of 32768 bytes. If the list contains null capable columns then an additional byte
is required for each null capable column. If the index contains variable length columns,
then the 2-byte length of the columns is included in the total length. The key length may be
too long if an ICU (UNICODE) table is being used. The internal expansion of the key can
be up to six times the user specified key length due to translation. See previous messages
for details.
Recovery Text: Reduce the length by deleting some of the columns from the CREATE INDEX column list.
Try the request again.
SQLCODE or -614
SQLCODEs:
SQLSTATE or 54008
SQLSTATEs:
SQL0615
Message Text: Object &1 in &2 type *&3 not dropped. It is in use.
Cause Text: Object &1 in &2 type *&3 was not dropped because it is already being used by the same
application process. If the object is a table, it may be in use by an open cursor. If the object
is an SQL package, the package may currently be running.
Recovery Text: If the object is a table, the cursor must be closed. If the object is an SQL package, the SQL
package cannot drop itself. Try the drop request again.
SQLCODE or -615
SQLCODEs:
SQLSTATE or 55006
SQLSTATEs:
SQL0616
Message Text: &1 in &2 type &3 cannot be dropped with RESTRICT.
Cause Text: An attempt was made to drop &1 in &2 with the RESTRICT option. &1 cannot be dropped
because a view, a constraint, or an index is dependent on it.
SQL0624
Message Text: Table &1 in &2 already has a primary key.
Cause Text: An attempt was made to add a primary or unique key to table &1 in &2. Either a primary
key is already defined for this table, or the table has an access path which does not match
the key being added. A table can only have one primary key. The constraint cannot be
added.
Recovery Text: Drop the primary key currently defined on the table or add the constraint as a UNIQUE
constraint. If the table’s access path does not match, make sure that the number of columns
in the constraint match the number of columns in the access path. Try the request again.
SQLCODE or -624
SQLCODEs:
SQLSTATE or 42889
SQLSTATEs:
SQL0628
Message Text: Clauses not valid in same definition.
Cause Text: Clauses specified to define the attributes of a column, a sourced function, or a trigger are
not valid. One of the following has occurred:
v More than one of the clauses FOR BIT DATA, FOR SBCS DATA, FOR MIXED DATA, or
CCSID was specified for a column definition.
v READ PERMISSION FS and WRITE PERMISSION BLOCKED were specified for a
DataLink column.
v READ PERMISSION DB and WRITE PERMISSION FS were specified for a DataLink
column.
v WRITE PERMISSION FS and the ON UNLINK clause were specified for a DataLink
column.
v INCLUDING or EXCLUDING COLUMN DEFAULTS and USING TYPE DEFAULTS were
specified for a table.
v A clause was specified that is not valid when creating a sourced function.
v FOR EACH STATEMENT is specified for a BEFORE or INSTEAD OF trigger or is
specified with MODE DB2ROW.
v MODE DB2SQL is specified for a BEFORE trigger and the trigger contains a reference to
the trigger table.
v A WHEN clause or an UPDATE column list is specified for an INSTEAD OF trigger.
v A correlation name with OLD ROW or NEW ROW and a SET OPTION for date or time
option were specified.
v The option specified on SET OPTION DBGVIEW is not consistent with the value
specified for the DEBUG MODE.
Recovery Text: Change or remove a clause so that the definition is valid. Try the request again.
SQLCODE or -628
SQLCODEs:
SQL0629
Message Text: SET NULL not allowed for referential constraint &1 in &2.
Cause Text: SET NULL was specified in the REFERENCES clause for referential constraint &1. None of
the columns in the foreign key allows null values.
Recovery Text: Create the table so that at least one of the columns in the foreign key allows null values or
specify a different default action on the ON DELETE clause. Try the request again.
SQLCODE or -629
SQLCODEs:
SQLSTATE or 42834
SQLSTATEs:
SQL0631
Message Text: Foreign key for referential constraint &1 in &2 too long.
Cause Text: The FOREIGN key cannot be created for constraint &1 in &2. Either more than 120 columns
were specified in a FOREIGN KEY clause or the sum of the lengths of the columns
specified in the key exceeds the maximum of 32768 bytes. If the list contains null capable
columns then an additional byte is required for the length of each null capable column. If
the list contains variable length columns, then the 2-byte length of the columns is included
in the total length.
Recovery Text: Remove some of the columns from the FOREIGN KEY clause. Try the request again.
SQLCODE or -631
SQLCODEs:
SQLSTATE or 54008
SQLSTATEs:
SQL0636
Message Text: Ranges specified for partition &1 not valid.
Cause Text: The ranges specified for the partitioning keys are not valid for one of the following reasons:
v Partitions are not specified in the correct order.
v ENDING value for a partition is less than the STARTING value.
v Values specified in the EVERY clause are not valid for the range.
v MINVALUE or MAXVALUE was specified for a start or end value and the statement
contained an EVERY clause.
v Partition keys overlap.
v MINVALUE or MAXVALUE was specified for a start or end value of a partition key
boundary and a subsequent key value for that range is not the same value.
Recovery Text: Specify valid ranges for the STARTING, ENDING, or EVERY clause. Try the request again.
SQLCODE or -636
SQLCODEs:
SQLSTATE or 56016
SQLSTATEs:
SQL0637
SQL0642
Message Text: Maximum number of constraints exceeded for &1 in &2.
Cause Text: A constraint cannot be added to table &1 in &2 because the table is already associated with
300 constraints. This limit includes all constraints defined on the table and all referential
constraints where the table is defined as a parent.
Recovery Text: Drop one of the other 300 constraints, if possible, and try the request again.
SQLCODE or -642
SQLCODEs:
SQLSTATE or 54021
SQLSTATEs:
SQL0644
Message Text: ATTRIBUTES value &1 not valid.
Cause Text: The ATTRIBUTES string specified for the PREPARE statement contains &1, which is not
correct. The type of SQL statement being prepared is &2.
Recovery Text: Remove or correct the invalid attribute and try again.
SQLCODE or -644
SQLCODEs:
SQLSTATE or 42615
SQLSTATEs:
SQL0645
Message Text: WHERE NOT NULL clause ignored for index &1 in &2.
Cause Text: UNIQUE WHERE NOT NULL was specified when creating index &1 in &2. However, none
of the columns in the index allow null values. The index is created as a unique index.
Recovery Text: Remove the WHERE NOT NULL clause from the CREATE INDEX statement.
SQLCODE or +645
SQLCODEs:
SQL0658
Message Text: Function &1 in &2 cannot be dropped.
Cause Text: Function &1 in schema &2 cannot be dropped because it was implicitly generated by the
CREATE DISTINCT TYPE statement.
Recovery Text: To drop the function, you must drop the distinct type with which this function is
associated.
SQLCODE or -658
SQLCODEs:
SQLSTATE or 42917
SQLSTATEs:
SQL0663
Message Text: Number of partitioning values is not correct.
Cause Text: Wrong number of values were specified in the STARTING or ENDING clause for partition
&1. The number of values specified must match the number of key columns for the
partitioning key. Only one column can be specified in the partitioning key if the EVERY
clause is used.
Recovery Text: Change the number of key limit values specified so that it matches the number of
partitioning key columns or change the number of columns in the partitioning key. Try the
request again.
SQLCODE or -663
SQLCODEs:
SQLSTATE or 53038
SQLSTATEs:
SQL0665
Message Text: The partition name or number &1 is not valid.
Cause Text: Partition name or partition number &1 was specified in a DROP PARTITION clause but
does not refer to a partition in the table. The partition name or number specified must
identify an existing partition from the table.
Recovery Text: Specify the partition name or number for an existing partition. Try the request again.
SQLCODE or -665
SQLCODEs:
SQLSTATE or 53039
SQLSTATEs:
SQL0666
Message Text: SQL query exceeds specified time limit or storage limit.
Cause Text: A database query was about to be started whose estimated run time of &1 exceeds the
specified limit of &2 or whose estimated temporary storage usage of &3 exceeds the
specified limit of &4. The query time limit and temporary storage limit are specified on the
CHGQRYA CL command.
SQL0667
Message Text: FOREIGN key value does not match a value in the parent key of constraint &1 in &2.
Cause Text: Every value in the FOREIGN key of the dependent table must have a matching value in the
parent key of the parent table. For constraint &1 in &2, there is an existing value in
FOREIGN key of table &3 in &4 that does not have a matching value in the parent table.
The constraint cannot be added.
Recovery Text: Update the rows in either the dependent table or parent table so that all values of the
FOREIGN key have matching values in the parent key, or modify the definition of the keys
in the referential constraint. Try the request again.
SQLCODE or -667
SQLCODEs:
SQLSTATE or 23520
SQLSTATEs:
SQL0675
Message Text: Specified delete rule not allowed with trigger on table &1 in &2.
Cause Text: The delete rule specified in referential constraint &3 in &4 on table &1 in &2 is not allowed
for the specified trigger. Constraint rule DELETE CASCADE is not allowed with a delete
trigger. Constraint rules DELETE SET NULL and DELETE SET DEFAULT are not allowed
with an update trigger.
SQL0678
Message Text: Data type of literal &1 not compatible with column &3.
Cause Text: The literal specified is not compatible. If literal &1 is specified for the STARTING,
ENDING, or EVERY clause, it is not compatible with column &3. The data type of column
&3 is &2. If the literal is specified in a comparison with a numeric value, the literal is not a
valid numeric value.
Recovery Text: Specify a valid literal. Try the request again.
SQLCODE or -678
SQLCODEs:
SQLSTATE or 53045
SQLSTATEs:
SQL0679
Message Text: Object &1 in &2 type *&3 not created due to pending operation.
Cause Text: The object &1 has an outstanding DROP or CREATE under commitment control which is
preventing the create. This could have occurred in one of the following ways:
v This application process has performed a DROP under commitment control which has
not been committed and is now trying to create the same object using commitment
control level *NONE.
v A different application process has performed a DROP under commitment control which
has not been committed.
v This application process has performed a DROP under commitment control using a
different commit definition and the DROP has not been committed.
v This application process has performed a CREATE under commitment control which has
not been committed and is now trying to use the object on a subsequent CREATE under
commitment control level *NONE.
Recovery Text: Do one of the following and try the request again:
v If it was your application process which issued the uncommitted DROP or CREATE
statement then issue a COMMIT before attempting the creation of the object or issue the
CREATE statement from a program using a commitment control level other than *NONE.
v If the application process that issued the DROP on this object is not your application,
then that application process must perform a COMMIT or a ROLLBACK of the DROP
statement.
v If your application process issued the uncommitted DROP or CREATE statement under a
different commit definition, issue a COMMIT or ROLLBACK for that commit definition.
SQLCODE or -679
SQLCODEs:
SQLSTATE or 57006
SQLSTATEs:
SQL0683
Message Text: Clause not valid for specified type.
Cause Text: One of the following has occurred:
v The FOR BIT DATA, the FOR MIXED DATA, the FOR SBCS DATA, or the CCSID clause
was specified for the CAST scalar function, for a CREATE DISTINCT TYPE source data
type, or for column or parameter &1. These clauses are not valid if the type is numeric,
date, time, timestamp, binary, or a user defined type. The FOR BIT DATA, FOR MIXED
DATA, or FOR SBCS DATA clause is not valid if the type is graphic or DataLink.
v The LINKTYPE option was specified for a column that is not a DataLink.
Recovery Text: If the CCSID clause is specified, change the specified type to be character, varying-length
character, CLOB, graphic, varying-length graphic, DBCLOB, or DATALINK. If the FOR BIT
DATA, FOR MIXED DATA, FOR SBCS DATA clause is specified, change the type to be
character, varying-length character, or CLOB. If the type is correct, remove the clause. If the
LINKTYPE option is specified, change the specified type to be DataLink or remove the
clause.
SQLCODE or -683
SQLCODEs:
SQLSTATE or 42842
SQLSTATEs:
SQL0696
Message Text: Correlation name or table &3 not valid.
Cause Text: The correlation name or table &3 is not valid for trigger &1 in &2. The reason code is &4.
One of the following reason codes indicates the error: 1 - NEW correlation name or
NEW_TABLE &3 was specified in a DELETE trigger. 2 - OLD correlation name or
OLD_TABLE &3 was specified in an INSERT trigger. 3 - OLD_TABLE or NEW_TABLE was
specified in a BEFORE trigger or was specified with DB2ROW.
Recovery Text: Change the referencing clause or the type of trigger so that the statement is valid. Try the
request again.
SQLCODE or -696
SQLCODEs:
SQLSTATE or 42898
SQLSTATEs:
SQL0697
Message Text: REFERENCING OLD or NEW not valid for statement trigger.
SQL0707
Message Text: Name &1 in &2 not allowed.
Cause Text: Name &1 is not allowed.
v Distinct type or sequence &1 in &2 cannot be created. Either the name is a reserved word
or the schema is specified as QSYS, QSYS2, SYSIBM, or QTEMP. Distinct types and
sequences cannot be created in QSYS, QSYS2, SYSIBM, or QTEMP.
v Savepoint &1 cannot have a name that starts with SYS.
Recovery Text: Change the name to a non-reserved word, or create the user-defined data type or sequence
in a schema other than QSYS, QSYS2, SYSIBM, or QTEMP.
SQLCODE or -707
SQLCODEs:
SQLSTATE or 42939
SQLSTATEs:
SQL0713
Message Text: Value for &2 is not correct.
Cause Text: The value specified in the SET &2 statement is not correct. The NULL value cannot be used
to set the &2 special register. &2 can only be set using a character or UCS-2 or UTF-16
graphic string. If this is SET ENCRYPTION PASSWORD WITH HINT, the hint value cannot
be longer than 32 characters. If this is SET SCHEMA, all letters in the schema name must
be uppercase or the schema name must be delimited. If this is SET CURRENT DEGREE,
the value cannot be longer than 5 characters. If this is a SET SESSION AUTHORIZATION,
the authorization name cannot be longer than 10 characters. An authorization name
specified as a string literal or with a host variable cannot contain the special register strings
USER, SYSTEM_USER, or SESSION_USER and cannot contain lowercase letters or special
characters.
Recovery Text: Specify a valid value for the special register. Make sure it does not have the NULL value.
Try the request again.
SQLCODE or -713
SQLCODEs:
SQLSTATE or 3F000, 42815
SQLSTATEs:
SQL0723
Message Text: SQL trigger &1 in &2 failed with SQLCODE &3 SQLSTATE &4.
Cause Text: An error has occurred in a triggered SQL statement in trigger &1 in schema &2. The
SQLCODE is &3, the SQLSTATE is &4, and the message is &5.
Recovery Text: Refer to the joblog for more information regarding the detected error. Correct the error and
try the request again.
SQL0724
Message Text: Too many cascaded trigger programs.
Cause Text: The maximum depth of 200 cascaded triggers has been exceeded.
Recovery Text: Remove any trigger that is causing repeated trigger programs to be called for the same
table.
SQLCODE or -724
SQLCODEs:
SQLSTATE or 54038
SQLSTATEs:
SQL0751
Message Text: SQL statement &1 not allowed.
Cause Text: The statement &1 is not allowed in a stored procedure, user-defined function, or trigger.
v Statements not allowed in a trigger program are CONNECT, SET CONNECTION,
RELEASE, DISCONNECT, and SET RESULT SETS.
v RUNSQLSTM is not allowed in a trigger program.
v COMMIT and ROLLBACK are not allowed in a trigger program if the trigger program is
running in the same activation group as the triggering program. COMMIT and
ROLLBACK are not allowed in an SQL trigger.
v ALTER TABLE is not allowed in a trigger program when commitment control is active.
v Statements not allowed in a stored procedure or user-defined function that is running on
a remote application server are CONNECT, SET CONNECTION, RELEASE,
DISCONNECT, COMMIT, ROLLBACK, and SET TRANSACTION.
v Statements not allowed in an SQL BEFORE trigger are INSERT, UPDATE, DELETE,
ALTER TABLE, COMMENT ON, CREATE, DROP, GRANT, LABEL ON, RENAME,
REVOKE, REFRESH TABLE, and ALTER PROCEDURE.
v The RETURN statement is not allowed in an SQL trigger.
v Statements not allowed in a secondary thread are CREATE TRIGGER, CREATE
FUNCTION (SQL), CREATE PROCEDURE (SQL), and ALTER PROCEDURE (SQL).
Recovery Text: Remove the statement &1 from your trigger program, user-defined function, or stored
procedure. Try the request again.
SQLCODE or -751
SQLCODEs:
SQLSTATE or 0W000, 2F003, 38003, 42985, 42987
SQLSTATEs:
SQL0752
Message Text: Connection cannot be changed. Reason code is &1.
SQL0771
Message Text: Table with ROWID column not allowed in QTEMP.
Cause Text: A table with a ROWID column cannot be created in QTEMP.
Recovery Text: Remove the ROWID column or create the table in a schema other than QTEMP. Try the
request again.
SQLCODE or -771
SQLCODEs:
SQL0773
Message Text: Case not found for CASE statement.
Cause Text: A CASE statement without an ELSE clause was specified in the routine body of an SQL
procedure. None of the conditions specified in the CASE statement were met.
Recovery Text: Change the CASE statement to handle all conditions that can occur.
SQLCODE or -773
SQLCODEs:
SQLSTATE or 20000
SQLSTATEs:
SQL0774
Message Text: Statement cannot be executed within a compound SQL statement.
Cause Text:
Recovery Text:
SQLCODE or -774
SQLCODEs:
SQLSTATE or 2D522
SQLSTATEs:
SQL0775
Message Text: Statement not allowed in specified SQL routine.
Cause Text: A statement specified in the routine body of an SQL procedure or function is not allowed.
A list of restrictions follows:
v A COMMIT or ROLLBACK statement cannot be specified in an atomic compound
statement in an SQL procedure.
v An ATOMIC compound statement cannot be specified in an SQL function.
v COMMIT, ROLLBACK, CONNECT, DISCONNECT, SET CONNECTION, SET RESULT
SETS, and SET TRANSACTION statements cannot be specified in an SQL function.
v The SET RESULT SETS statement cannot be specified in an SQL routine body unless
RESULT SET is specified for the procedure.
Recovery Text: Remove the statement from the SQL function or procedure.
SQLCODE or -775
SQLCODEs:
SQLSTATE or 42910
SQLSTATEs:
SQL0776
Message Text: Cursor &1 specified in FOR statement not allowed.
Cause Text: Cursor &1 is specified as the cursor name on a FOR statement in an SQL procedure. The
cursor cannot be specified on a FETCH, OPEN, or CLOSE statement within the FOR
statement.
Recovery Text: Remove the OPEN, CLOSE, or FETCH statement.
SQL0777
Message Text: Nested compound statements not allowed.
Cause Text: Compound statements in the routine body of an SQL procedure or function cannot be
nested.
Recovery Text:
SQLCODE or -777
SQLCODEs:
SQLSTATE or 42919
SQLSTATEs:
SQL0778
Message Text: End label &1 not same as begin label.
Cause Text: Label &1 specified at the end of a compound, FOR, WHILE, REPEAT, or LOOP statement
in an SQL procedure or function is not the same as the label at the beginning of the
statement. The end label cannot be specified if the begin label is not specified.
Recovery Text: Ensure the end label is the same as the begin label for compound, FOR, WHILE, REPEAT,
and LOOP statements.
SQLCODE or -778
SQLCODEs:
SQLSTATE or 428D5
SQLSTATEs:
SQL0779
Message Text: Label &1 specified not valid.
Cause Text: Label &1 is specified on a LEAVE or a GOTO statement in an SQL procedure or function.
The label is not a valid label or is not in the same scope as the current statement.
Recovery Text: Specify a valid label that is within the same scope. Try the request again.
SQLCODE or -779
SQLCODEs:
SQLSTATE or 42736
SQLSTATEs:
SQL0780
Message Text: UNDO specified for a handler not valid.
Cause Text: UNDO is specified for a handler in a compound statement in an SQL procedure, function,
or trigger. UNDO cannot be specified unless the compound statement is ATOMIC. UNDO
cannot be specified in a trigger.
Recovery Text: Either specify an ATOMIC compound statement or specify EXIT or CONTINUE on the
handler.
SQLCODE or -780
SQLCODEs:
SQL0781
Message Text: Condition &1 specified in handler not defined.
Cause Text: Condition &1 specified in a handler in an SQL procedure or function is not defined.
Recovery Text: Define the condition using the DECLARE CONDITION statement or remove the condition
from the handler.
SQLCODE or -781
SQLCODEs:
SQLSTATE or 42737
SQLSTATEs:
SQL0782
Message Text: Condition value &1 specified in handler not valid.
Cause Text: Condition &1 specified in a handler in an SQL procedure or function is not valid for one of
the following reasons:
v The condition value has already been specified by another handler in the same scope.
v The condition or SQLSTATE was specified in the same handler as SQLEXCEPTION,
SQLWARNING, or NOT FOUND.
Recovery Text: Remove the condition from the handler.
SQLCODE or -782
SQLCODEs:
SQLSTATE or 428D7
SQLSTATEs:
SQL0783
Message Text: Select list for cursor &1 in FOR statement not valid.
Cause Text: The select list in the FOR statement must contain unique column names. The select list
specified either contains duplicate column names or unnamed expressions. If two column
names are the same, the column name is &2.
Recovery Text: Specify unique column names in the select list specified in the FOR statement.
SQLCODE or -783
SQLCODEs:
SQLSTATE or 42738
SQLSTATEs:
SQL0784
Message Text: Constraint &1 cannot be dropped.
Cause Text: Constraint &1 is a CHECK constraint or a UNIQUE constraint. It cannot be dropped
because it is enforcing a primary key to be not null or a ROWID to be unique.
SQL0785
Message Text: Use of SQLCODE or SQLSTATE not valid.
Cause Text: SQLCODE or SQLSTATE was used as a variable in the routine body of an SQL procedure,
but is not valid for one of the following reasons:
v SQLCODE is not declared as INT.
v SQLSTATE is not declared as CHAR(5).
v The variable is set to NULL.
Recovery Text: Declare the SQLCODE variable as INT and the SQLSTATE variable as CHAR(5). Set the
variable to a valid value.
SQLCODE or -785
SQLCODEs:
SQLSTATE or 428D8
SQLSTATEs:
SQL0787
Message Text: RESIGNAL statement not within a handler.
Cause Text: The RESIGNAL statement, specified in an SQL routine, must be specified inside a handler.
Recovery Text: Remove the RESIGNAL statement or use a SIGNAL statement. Try the request again.
SQLCODE or -787
SQLCODEs:
SQLSTATE or 0K000
SQLSTATEs:
SQL0798
Message Text: Value cannot be specified for GENERATED ALWAYS column &1.
Cause Text: A value cannot be specified for column &1 because it is defined as GENERATED ALWAYS.
Recovery Text: Do one of the following and try the request again:
v Remove the value from the INSERT or UPDATE statement, or specify DEFAULT to have
a system value generated for the column.
v Specify the OVERRIDING USER VALUE clause on the INSERT or UPDATE statement to
override the GENERATED ALWAYS attribute and assign the value to the column
v Remove the column from the SET statement.
SQLCODE or -798
SQLCODEs:
|| SQL0799
| Message Text: Special register &1 does not exist at the application server.
| Cause Text: A SET statement references special register &1. This special register does not exist on the
| application server so it cannot be referenced in the statement.
| Recovery Text: Remove the reference to the unsupported special register from the statement. Try the
| request again.
| SQLCODE or +799
| SQLCODEs:
| SQLSTATE or 01527
| SQLSTATEs:
|
SQL0802
Message Text: Data conversion or data mapping error.
Cause Text: Error type &3 has occurred. Error types and their meanings are:
v 1 - Arithmetic overflow.
v 2 - Floating point overflow.
v 3 - Floating point underflow.
v 4 - Floating point conversion error.
v 5 - Not an exact result.
v 6 - Numeric data that is not valid.
v 7 - Double-byte character set (DBCS) data that is not valid.
v 8 - Division by zero.
v 9 - Hash value cannot be computed for the requested query.
v 10 - User-defined function returned a mapping error.
v 11 - Not valid length found in a varying-length column returned from an array result set.
v 12 - Result of a concatenation operation on a varying-length field exceeded the maximum
allowed length of the result type. If the error occurred when assigning a value to a host
variable of a FETCH, embedded SELECT, SET, or VALUES INTO statement, the host
variable name is &2 and the relative position of the host variable in the INTO clause is
&1. If the host variable name is *N, the error occurred when attempting to resolve a
search condition. If more than one data mapping error occurred, this is a description of
the first error that occurred. For a description of any other data mapping errors, see the
previously listed messages in the job log.
Recovery Text: The error was caused by data that was not valid or that was too large. Look at the
previously listed messages in the job log (DSPJOBLOG command) or press F10 (Display
messages in job log) on this display to determine what row and columns were involved in
the error. Correct the data and then try the request again.
SQLCODE or +802, -802
SQLCODEs:
SQLSTATE or 01004, 01519, 01547, 01564, 01565, 22001, 22003, 22012, 22023, 22504
SQLSTATEs:
SQL0803
Message Text: Duplicate key value specified.
SQL0804
Message Text: SQLDA or descriptor area not valid.
Cause Text: If the error type is 2, 3, 9, 12, or 13, the entry in error is &2, the value of SQLTYPE or TYPE
is &3, and the value of SQLLEN, SQLLONGLEN, or LENGTH is &4. If the error type is 13,
the &5 was being set when the inconsistency was found. The specified SQLDA or
descriptor area is not valid because of error type &1. Error types and their meanings are:
v 1 - The value of SQLN is less than zero, the value of SQLD is not between 0 and 8000,
the value of SQLD is greater than the value of SQLN, or that the value of SQLD has not
been initialized in REXX.
v 2 - The value of SQLTYPE is either not valid or not supported or has not been initialized
in REXX. The types that are not supported in REXX are NUL-terminated graphic string,
NUL-terminated character string, PASCAL L-string, sign leading separate, and binary
with precision and scale.
v 3 - The value of SQLLEN or SQLLONGLEN is not valid or the value of SQLLEN,
SQLPRECISION, or SQLSCALE has not been initialized in REXX. If REXX and SQLTYPE
is decimal or numeric, then either SQLPRECISION or SQLSCALE has not been
initialized. Otherwise, SQLLEN has not been initialized. If SQLTYPE is a LOB variable,
then SQLLONGLEN is not valid.
v 5 - The SQLDA area was not on a 16-byte boundary.
v 6 - The value specified for SQLDABC is not valid. The value is either not large enough
for the number of entries specified in SQLN or the value is greater than the maximum
allowed.
v 7 - The value of SQLN was not at least twice the size of SQLD and LOB host variables
were found in the SQLDA.
v 8 - The seventh byte of SQLDAID was not a ’2’, ’3’ or ’4’ and LOB host variables were
found in the SQLDA.
v 9 - The SQLDATAL pointer was not null for a DBCLOB host variable, but the length
value referenced by the SQLDATAL pointer had an odd value.
v 10 - The SQLTYPE for a LOB locator did not match the type associated with LOB locator.
v 11 - The row length is greater than the maximum allowed row length.
v 12 - The TYPE for an item in the descriptor area has not been set.
v 13 - The attributes of the item in the descriptor area are not consistent. TYPE, LENGTH,
PRECISION, SCALE, DB2_CCSID, and DATETIME_INTERVAL_CODE need to be
consistent with one another for each item set with the SET DESCRIPTOR statement.
Recovery Text: Correct the error in the SQLDA or descriptor area and try the request again.
SQLCODE or -804
SQLCODEs:
SQLSTATE or 07002
SQLSTATEs:
SQL0809
Message Text: Row length exceeds 3.5 gigabytes.
Cause Text: The lengths of the values used as input in the INSERT or UPDATE statement would cause
the row length to exceed the maximum length of 3.5 gigabytes.
Recovery Text: Change the statement so that the sum of all field lengths result in a row length of less than
3.5 gigabytes.
SQLCODE or -809
SQLCODEs:
SQLSTATE or 54018
SQLSTATEs:
SQL0811
Message Text: Result of SELECT more than one row.
Cause Text: The result table of a SELECT INTO statement, a subquery, or a subselect of a SET statement
contains more than one row. The error type is &1. If the error type is 1 then a SELECT
INTO statement attempted to return more than one row. If the error type is 2 then a
subselect of a basic predicate has produced more than one row. Only one row is allowed.
Recovery Text: Change the selection so that only one result row is returned and then try the request again.
The DECLARE CURSOR, OPEN, and FETCH statements must be used to process more
than one result row. For a subquery the IN, EXISTS, ANY or ALL predicates can be used to
process more than one result row. If one row was expected, there may be data errors, such
as duplicate rows, that are causing more than one row to be returned.
SQLCODE or -811
SQLCODEs:
SQLSTATE or 21000
SQLSTATEs:
SQL0818
Message Text: Consistency tokens do not match.
Cause Text: Package &3 in &4 on application server &5 cannot be run with the current application
program because either the application program has been recompiled without rebuilding
the package or the package has been restored from a back level version.
Recovery Text: Rebuild the package by using the CRTSQLPKG command or by using a CRTSQLxxx
command specifying the correct relational database. Otherwise, restore the package from a
version which matches the application program being run.
SQLCODE or -818
SQLCODEs:
SQLSTATE or 51003
SQLSTATEs:
SQL0822
Message Text: Address in the SQLDA or descriptor area not valid.
Cause Text: The SQLDA or descriptor area contains an address, SQLDATA or DATA value, or SQLIND
or INDICATOR value in entry number &1 that is not valid. The incorrect address or value
is type &2.
v Type 1 indicates that the SQLDATA or DATA address is not valid.
v Type 2 indicates that the SQLIND or INDICATOR address is not valid.
v Type 3 indicates that the SQLDA address is not valid.
v Type 4 indicates that the row storage area is not large enough.
v Type 5 indicates that the indicator area for a blocked FETCH statement is not large
enough.
v Type 6 indicates that the SQLDATA field was not initialized to a value in a REXX
procedure.
v Type 7 indicates that the SQLIND field was not initialized to a value in a REXX
procedure.
v Type 8 indicates that the SQLDATAL address is not valid.
Recovery Text: For types 1, 2, 3, or 8, change the address in entry &1 to a valid address. For types 4 and 5,
allocate enough area for all of the rows being requested. For types 6 and 7, initialize the
SQLDATA or SQLIND fields to a valid value. Try the request again.
SQLCODE or -822
SQLCODEs:
SQLSTATE or 51004
SQLSTATEs:
SQL0840
Message Text: Number of selected items exceeds 8000.
Cause Text: The number of items returned in a select list or presented in the insert list exceeds the
maximum of 8000.
Recovery Text: Reduce the number of selected items and try the request again.
SQLCODE or -840
SQLCODEs:
SQLSTATE or 54004
SQLSTATEs:
SQL0842
Message Text: Connection to relational database &1 already exists.
Cause Text: An attempt was made to do one of the following:
v CONNECT to a relational database when the connection is active.
v CONNECT to a relational database that has the same communication information as a
connection to a relational database that is active. The active relational database is &1.
Recovery Text: If CONNECT was specified, either use the SET CONNECTION statement to make
relational database &1 the current connection or change the RDB directory entry
(CHGRDBDIRE) for the relational database you are connecting to so that at least part of the
communication information is different from what is specified in the entry for &1. For
APPC connections, the communication information is the remote location, device
description, local location, remote network identifier, mode, and transaction program. For
TCP/IP connections, the communication information is the remote location and port
identification.
SQLCODE or -842
SQLCODEs:
SQLSTATE or 08002
SQLSTATEs:
SQL0843
Message Text: Connection to relational database &1 does not exist.
Cause Text: A SET CONNECTION, RELEASE, or DISCONNECT statement specified relational database
name &1 which is not active.
Recovery Text: Specify the name of a relational database which has an active connection.
SQLCODE or -843
SQLCODEs:
SQL0845
Message Text: PREVIOUS VALUE for sequence &1 cannot be used.
Cause Text: A PREVIOUS VALUE expression specified sequence &1 in &2, but a value is not available
in this application process.
v A NEXT VALUE expression must be evaluated before a PREVIOUS VALUE expression
can be used.
v A NEXT VALUE expression must be evaluated after a sequence is altered or dropped.
Recovery Text: Evaluate the NEXT VALUE expression for sequence &1 in &2 in the same application
process before using PREVIOUS VALUE.
SQLCODE or -845
SQLCODEs:
SQLSTATE or 51035
SQLSTATEs:
SQL0846
Message Text: Attributes not valid for IDENTITY column or sequence.
Cause Text: Error &6 occurred for an IDENTITY column or sequence. For an IDENTITY column, &2 in
schema &3 is the name of the table. For a sequence, &2 in &3 is the name of the sequence.
v Code 1 - The data type of an IDENTITY column or sequence is not INTEGER, BIGINT,
SMALLINT, or DECIMAL or NUMERIC with a scale of zero. An IDENTITY column that
is DECIMAL or NUMERIC must have a precision less than or equal to 31.
v Code 2 - The value specified for START WITH, INCREMENT BY, MINVALUE, or
MAXVALUE is outside the range for the data type specified.
v Code 3 - The value specified for MINVALUE is larger than the value specified for
MAXVALUE.
v Code 4 - The value specified for CACHE is not valid. The minimum value for CACHE is
2.
v Code 7 - A sequence can only be altered to a distinct type if the current data type is a
built-in data type and it is promotable to the source data type of the distinct type. If the
current data type is a distinct type, it can only be changed to its source data type.
Recovery Text: Specify valid attributes for the IDENTITY column or sequence. Try the request again.
SQLCODE or -846
SQLCODEs:
SQLSTATE or 42815
SQLSTATEs:
SQL0858
Message Text: Cannot disconnect relational database &1 due to LU6.2 protected conversation.
Cause Text: The DISCONNECT statement cannot be used to disconnect relational database &1 because
the conversation uses an LU6.2 protected conversation.
Recovery Text: Use the RELEASE statement followed by a COMMIT statement to end LU6.2 protected
conversations.
SQLCODE or -858
SQLCODEs:
SQL0862
Message Text: Local program attempted to connect to a remote relational database.
Cause Text: Local program &1 in &2 attempted to connect to a remote relational database. Either the
CONNECT statement or the SET CONNECTION statement was specified and the relational
database specified was a remote relational database.
Recovery Text: Specify the RDB parameter on the SQL precompile command.
SQLCODE or -862
SQLCODEs:
SQLSTATE or 55029
SQLSTATEs:
SQL0863
Message Text: Mixed or DBCS CCSID not supported by relational database &1.
Cause Text: The connection was completed, but remote relational database &1 does not support either
the mixed or DBCS CCSID. SBCS data can be used. The product identification is &2.
Recovery Text: No recovery needed.
SQLCODE or +863
SQLCODEs:
SQLSTATE or 01539
SQLSTATEs:
SQL0871
Message Text: Too many CCSID values specified.
Cause Text: More than 80 unique combinations of character data type and Coded Character Set
Identifier (CCSID) were used. When accessing remote data, there is a limit of 80 different
CCSID values.
Recovery Text: Change that request to only access 80 different combinations of character data type and
CCSID.
SQLCODE or -871
SQLCODEs:
SQLSTATE or 54019
SQLSTATEs:
SQL0880
Message Text: Savepoint &1 does not exist or is not valid in this context.
Cause Text: The RELEASE TO SAVEPOINT or ROLLBACK TO SAVEPOINT statement does not identify
a savepoint that exists at the current savepoint level.
Recovery Text: Correct the statement to use a valid savepoint name, then try the statement again.
SQLCODE or -880
SQLCODEs:
SQLSTATE or 3B001
SQLSTATEs:
SQL0882
Message Text: Savepoint does not exist.
Cause Text: A ROLLBACK TO SAVEPOINT without a savepoint name was attempted but no savepoint
exists at the current savepoint level.
Recovery Text: Correct the application logic to either set a savepoint or to not attempt to rollback to a
savepoint.
SQLCODE or -882
SQLCODEs:
SQLSTATE or 3B502
SQLSTATEs:
SQL0900
Message Text: Application process not in a connected state.
Cause Text: One of the following occurred:
v The current connection was disconnected using the DISCONNECT statement.
v The current connection was released and a commit occurred
v A previous error has left the application process in an unconnected state. Use the Display
Job Log (DSPJOBLOG) command to see previous errors.
Recovery Text: Issue CONNECT statement with the TO or RESET clause or the SET CONNECTION
statement to enter the connected state.
SQLCODE or -900
SQLCODEs:
SQLSTATE or 08003
SQLSTATEs:
SQL0901
Message Text: SQL system error.
Cause Text: An SQL system error has occurred. The current SQL statement cannot be completed
successfully. The error will not prevent other SQL statements from being processed.
Previous messages may indicate that there is a problem with the SQL statement and SQL
did not correctly diagnose the error. The previous message identifier was &1. Internal error
type &2 has occurred. If precompiling, processing will not continue beyond this statement.
Recovery Text: See the previous messages to determine if there is a problem with the SQL statement. To
view the messages, use the DSPJOBLOG command if running interactively, or the WRKJOB
command to view the output of a precompile. An application program receiving this return
code may attempt further SQL statements. Correct any errors and try the request again.
SQL0904
Message Text: Resource limit exceeded.
Cause Text: Resource limit type &1 exceeded with reason code &2. A list of the limit types follows:
v Type 1 indicates that the user profile storage limit or the machine storage limit was
exceeded.
v Type 2 indicates that the machine lock limit was exceeded.
v Type 3 indicates that the query resource limit was exceeded. For more information see
the previously listed message CPD4365.
v Type 4 indicates that a journal error has occurred.
v Type 5 indicates that the commit lock limit was exceeded.
v Type 6 indicates that the maximum size of the table has been reached.
v Type 7 indicates that the maximum size of the prepared statement area has been reached.
v Type 8 indicates that the maximum number of cursors have been opened for this job.
v Type 9 indicates that the maximum number of entries in the lock table have been used
for this job.
v Type 12 indicates that the maximum DRDA communications buffer size was exceeded.
v Type 13 indicates that the maximum amount of blocked data was exceeded.
v Type 14 indicates that the maximum amount of descriptor space has been allocated.
Recovery Text: Do one of the following:
v If this is error type 1, contact the security officer to increase the user profile storage limit,
or delete some objects to free up storage and then try the request again.
v If this is error type 2, then try the operation when the number of machine locks held has
decreased.
v If this is error types 3, 4, or 5, see previously listed messages in the job log for recovery
information.
v If this is error type 6, Some of the rows from this table must be moved to another table.
v If this is error type 7, issue a COMMIT or ROLLBACK without the HOLD clause before
issuing anymore PREPARE statements.
v If this is error type 8, issue a CLOSE before issuing any more OPEN statements.
v If this is error type 9, issue a COMMIT or ROLLBACK without the HOLD clause.
v If this is error type 12, reduce the total size of column data supplied with the SQL
request.
v If this is error type 13, reduce the number of rows in the block.
v If this is error type 14, reduce the number of allocated descriptors with the
DEALLOCATE DESCRIPTOR statement.
SQLCODE or -904
SQLCODEs:
SQLSTATE or 57011
SQLSTATEs:
SQL0906
Message Text: Operation not performed because of previous error.
SQL0907
Message Text: Data change violation occurred.
Cause Text: The row referenced by the statement which caused a trigger program to be invoked was
referenced again in the trigger program. The reference in the trigger program attempted to
update or delete the row. This is called a destructive data change and is not allowed.
Recovery Text: Remove the statement which caused the error from your trigger program and attempt the
request again.
SQLCODE or -907
SQLCODEs:
SQLSTATE or 27000
SQLSTATEs:
SQL0910
Message Text: Object &1 in &2 type *&3 has a pending change.
Cause Text: Object &1 has an outstanding change made under commitment control that is preventing
this operation. One of the following may have occurred:
v This application process performed an operation on this object under commitment
control. The operation has not been committed. The application process is now
attempting to change the same object using commitment control level *NONE.
v A different application process has performed an operation on this object under
commitment control. The operation has not been committed.
v This application process has performed an operation on this object under commitment
control using a different commit definition. The operation has not been committed.
v This application process has performed an operation on this object under commitment
control. The operation has not been committed. The table cannot be altered until the
changes are committed or rolled back.
Recovery Text: Do one of the following and try the request again:
v If your application process issued the uncommitted operation, either issue a COMMIT or
ROLLBACK before attempting any other operations on this object, or issue the statement
from a program using a commitment control level other than *NONE.
v If the application process that issued the uncommitted operation on this object is not
your application process, then that application process must perform a COMMIT or a
ROLLBACK.
v If your application process issued the uncommitted operation using a different commit
definition, issue a COMMIT or ROLLBACK for that commit definition.
v Issue either a COMMIT or ROLLBACK before attempting an ALTER TABLE statement on
this object.
SQLCODE or -910
SQLCODEs:
SQLSTATE or 57007
SQLSTATEs:
SQL0918
Message Text: ROLLBACK is required.
Cause Text: The activation group requires a ROLLBACK to be performed prior to running any other
SQL statements.
Recovery Text: Issue a ROLLBACK CL command or an SQL ROLLBACK statement and then continue.
SQLCODE or -918
SQLCODEs:
SQLSTATE or 51021
SQLSTATEs:
SQL0950
Message Text: Relational database &1 not in relational database directory.
Cause Text: A request for relational database &1 was made. However the relational database name was
not found in the relational database directory.
Recovery Text: Do one of the following:
v Change the name of the relational database specified on the CONNECT, SET
CONNECTION, RELEASE, or DISCONNECT statement or the RDB parameter of the
SQL precompile commands.
v Add the relational database name to the relational database directory using the Add
Relational Database Directory Entry (ADDRDBDIRE) command.
SQL0951
Message Text: Object &1 in &2 not altered.
Cause Text: Object &1 in &2 was not altered because it, or a related object, is being used by the same
application process. A table may be related in a referential constraint relationship with
another table being used by the same application process.
Recovery Text: Close the cursor and try the alter request again.
SQLCODE or -951
SQLCODEs:
SQLSTATE or 55007
SQLSTATEs:
SQL0952
Message Text: Processing of the SQL statement ended. Reason code &1.
Cause Text: The SQL operation was ended before normal completion. The reason code is &1. Reason
codes and their meanings are:
v 1 - An SQLCancel API request has been processed, for example from ODBC.
v 2 - SQL processing was ended by sending an exception.
v 3 - Abnormal termination.
v 4 - Activation group termination.
v 5 - Reclaim activation group or reclaim resources.
v 6 - Process termination.
v 7 - An EXIT function was called.
v 8 - Unhandled exception.
v 9 - A Long Jump was processed.
v 10 - A cancel reply to an inquiry message was received.
v 11 - Open Database File Exit Program (QIBM_QDB_OPEN).
v 0 - Unknown cause.
Recovery Text: If the reason code is 1, a client request was made to cancel SQL processing. For all other
reason codes, see previous messages to determine why SQL processing was ended.
SQLCODE or -952
SQLCODEs:
SQLSTATE or 57014
SQLSTATEs:
SQL0969
Message Text: Error occurred while passing request to application requester driver program.
Cause Text: An unexpected error occurred while passing the SQL request to the application requester
driver program for relational database &1. See previously listed messages in the job log for
the cause of the failure.
Recovery Text: Correct any problems and try the request again.
SQL0971
Message Text: Constraint &4 in check pending state.
Cause Text: The operation being performed on table &2 in &3 failed. Constraint &4 in &5 could not be
enforced because of reason code &1. The reason codes and their meanings are:
v 1 - The dependent file is in check pending status due to a referential constraint violation.
v 2 - The dependent or parent file’s access path is not valid.
v 3 - The file is in check pending status due to a check constraint violation.
Recovery Text: For reason codes 1 and 3, use the CHGPFCST command to disable the constraint. Then use
the DSPCPCST command to see the records causing the check pending status. Correct the
data in the file and then use the CHGPFCST command to enable the constraint. For reason
code 2, use the EDTRBDAP command or Manage Index Rebuilds in iSeries Navigator to
rebuild the file’s access path.
SQLCODE or -971
SQLCODEs:
SQLSTATE or 57011
SQLSTATEs:
SQL0990
Message Text: Outcome unknown for the unit of work.
Cause Text: The unit of work completed but the outcome is not fully known at all sites. Either a
conversation failure occurred and resynchronization is occurring to correct the problem, or
a ROLLBACK occurred at one of the resources.
Recovery Text: No user action is necessary.
SQLCODE or +990
SQLCODEs:
SQLSTATE or 01587
SQLSTATEs:
|| SQL1530
| Message Text: SET CURRENT DEGREE statement not fully enabled.
| Cause Text: Parallel processing is not enabled on this machine because the system feature DB2 UDB
| Symmetric Multiprocessing is not installed on the system.
| Recovery Text:
| SQLCODE or +1530
| SQLCODEs:
| SQLSTATE or 01623
| SQLSTATEs:
|
SQL1583
Message Text: PAGESIZE value &1 not correct.
|| SQL1596
| Message Text: WITH EMPTY TABLE not valid for &1 in &2.
| Cause Text: The ALTER TABLE cannot have the WITH EMPTY TABLE clause specified for table &1 in
| &2. The table is either a materialized query table or the parent table in a referential
| constraint which conflicts with the WITH EMPTY TABLE clause.
| Recovery Text: Change the name of the table and try the request again.
| SQLCODE or -1596
| SQLCODEs:
| SQLSTATE or 42928
| SQLSTATEs:
|
SQL4300
Message Text: Java support is not installed or properly configured on this platform.
Cause Text: Support for Java stored procedures and user-defined functions is not installed and
configured on this server.
Recovery Text: Ensure that a compatible Java Development Kit is installed.
SQLCODE or -4300
SQLCODEs:
SQLSTATE or 42724
SQLSTATEs:
SQL4301
Message Text: Java interpreter startup or communication failed for reason code &1.
Cause Text: An error occurred while attempting to start or communicate with a Java interpreter. The
reason codes and their meanings follow:
v 1 - Java environment variables or Java database configuration parameters are invalid.
v 2 - A Java Native Interface call to the Java interpreter failed.
v 4 - The Java interpreter has terminated itself and cannot be restarted.
Recovery Text: Ensure that Java environment variables or Java database configuration parameters are valid.
Ensure that a Java method called by the Java interpreter does not use System.out. Ensure
that internal DB2 classes (com.ibm.db2) are not overridden by user classes.
SQLCODE or -4301
SQLCODEs:
SQLSTATE or 58004
SQLSTATEs:
SQL4303
Message Text: Java stored procedure or user-defined function &1, specific name &2, could not be
identified from external name &3.
Cause Text: The CREATE PROCEDURE or CREATE FUNCTION statement that declared this stored
procedure or user-defined function had a badly formatted EXTERNAL NAME clause. The
external name must be formatted as follows: ″package.subpackage.class.method″.
Recovery Text: Submit a corrected CREATE PROCEDURE or CREATE FUNCTION statement.
SQLCODE or -4303
SQLCODEs:
SQLSTATE or 42724
SQLSTATEs:
SQL4304
Message Text: Java stored procedure or user-defined function &1, specific name &2 could not load Java
class &3 for reason code &4.
Cause Text: The Java class given by the EXTERNAL NAME clause of a CREATE PROCEDURE or
CREATE FUNCTION statement could not be loaded. The reason codes and their meanings
are:
v 1 - The class was not found on the CLASSPATH.
v 2 - The class did not implement the required interface (″com.ibm.db2.app.StoredProc″ or
″com.ibm.db2.app.UDF″) or lacked the Java ″public″ access flag.
v 3 - The default constructor failed or was unavailable.
Recovery Text: Ensure that the compiled ″.class″ file is installed in the CLASSPATH, for example under
″/QIBM/UserData/OS400/SQLLib/Function″. Ensure it implements the required Java
interfaces and is ″public″.
SQLCODE or -4304
SQLCODEs:
SQLSTATE or 42724
SQLSTATEs:
SQL4306
Message Text: Java stored procedure or user-defined function &1, specific name &2 could not call Java
method &3, signature &4.
Cause Text: The Java method given by the EXTERNAL NAME clause of a CREATE PROCEDURE or
CREATE FUNCTION statement could not be found. Its declared argument list may not
match what the database expects, or it may not be a ″public″ instance method.
SQL4701
Message Text: Too many partitions specified.
Cause Text: One of the following has occurred:
v There are too many partitions specified on the CREATE TABLE statement.
v There was an attempt to add a partition to a existing table with an ALTER TABLE
statement but the table already has the maximum number of partitions. There is a
maximum of 256 partitions allowed in a partitioned table.
Recovery Text: For a CREATE TABLE statement, correct the number of partitions so that the number does
not exceed the maximum. For an ALTER TABLE statement, remove the ADD PART clause.
Try the request again.
SQLCODE or -4701
SQLCODEs:
SQLSTATE or 54054
SQLSTATEs:
SQL5001
Message Text: Column qualifier or table &2 undefined.
Cause Text: Name &2 was used to qualify a column name or was specified as the operand of the RRN,
HASHED_VALUE, PARTITION, NODENAME, NODENUMBER, DBPARTITIONNAME,
DBPARTITIONNUM, DATAPARTITIONNAME, or DATAPARTITIONNUM scalar function.
The name is not defined to be a table designator in this SQL statement or the table
designator cannot be referenced where it is specified in the SQL statement. If a correlation
name is specified following the table name in a FROM clause, the correlation name is
considered to be the table designator. If a correlation name is not specified, the table name
is considered to be the table designator. If using SQL naming and the table is qualified with
authorization name, then the table designator is authorization-name.table-name. If the
authorization name is not specified, the table designator is the implicit authorization name
followed by the table name. Correlation from a nested table expression to a higher level
table is only allowed if the TABLE keyword is used for the definition of the nested table
expression. If the name is *N, a lateral correlation reference from a nested table expression
is not allowed. You can not correlate to a table at a higher level than the nested table
expression for one of the following reasons:
v The nested table expression contains a UNION, EXCEPT, or INTERSECT.
v The nested table expression uses the DISTINCT keyword in the SELECT clause.
v The nested table expression contains an ORDER BY clause.
v The correlated provider is in the same FROM clause as the nested table expression but is
part of a RIGHT OUTER JOIN or RIGHT EXCEPTION JOIN.
v The nested table expression is in the FROM clause of another nested table expression that
contains one of these restrictions. In an OLAP function, the ORDER OF table designator
must refer to a table designator in the FROM clause of the subselect.
Recovery Text: Ensure all column names are qualified with a valid table designator. Make sure a table
designator is specified as the argument to the function. Use the TABLE keyword to allow
correlated columns within a nested table expression. Try the request again.
SQL5003
Message Text: Cannot perform operation under commitment control.
Cause Text: The following operations cannot be performed under commitment control with
COMMIT(*CHG), COMMIT(*CS), or COMMIT(*ALL) specified:
v DROP SCHEMA statement.
v GRANT or REVOKE statement to an object that has an authority holder.
v CREATE statement in SQL naming mode of an object that has an authority holder. These
operations cannot be committed or rolled back.
Recovery Text: Specify COMMIT(*NONE), and try the statement again.
SQLCODE or -5003
SQLCODEs:
SQLSTATE or 42922
SQLSTATEs:
SQL5005
Message Text: Operator &4 not consistent with operands.
Cause Text: The operator specified is not consistent with the previous operands. The arithmetic
operators (*, /, and **) are not valid with concatenation operators or with the DIGITS and
SUBSTR scalar functions. The concatenation operator is not valid with other operations or
functions that result in a numeric value, such as the arithmetic operators (* and /) or the
LENGTH, DECIMAL, FLOAT, or INTEGER scalar functions.
Recovery Text: Change the SQL statement so all expressions are valid numeric expressions, string
expressions, or date/time expressions.
SQLCODE or -5005
SQLCODEs:
SQLSTATE or 42815
SQLSTATEs:
SQL5012
Message Text: Host variable &1 not numeric with zero scale.
Cause Text: Host variable &1 was specified in a position where it is not allowed. The host variable was
not usable for one of the following reasons:
v It is not numeric.
v The scale is not zero.
Recovery Text: Change the host variable to a numeric type with zero scale.
SQLCODE or -5012
SQLCODEs:
SQLSTATE or 42618
SQLSTATEs:
SQL5017
Message Text: Too many users specified for GRANT or REVOKE.
Cause Text: More than the maximum of 50 users are specified on the GRANT or REVOKE statement.
Recovery Text: Change the GRANT or REVOKE statement to specify a maximum 50 users. Try the request
again.
SQLCODE or -5017
SQLCODEs:
SQLSTATE or 54009
SQLSTATEs:
SQL5021
Message Text: FOR UPDATE column &1 not valid.
Cause Text: One of the following has occurred:
v A column in the FOR UPDATE clause is specified in the ORDER BY clause. If the column
name is *N, a list of columns was not specified in the FOR UPDATE clause. This is the
same as listing all columns.
v A DATALINK column in the FOR UPDATE clause is specified in the SELECT list.
Recovery Text: Remove the duplicate column from one of the clauses. If no columns were specified in the
FOR UPDATE clause, remove either the FOR UPDATE clause or the ORDER BY clause. Try
the request again.
SQLCODE or -5021
SQLCODEs:
SQLSTATE or 42930
SQLSTATEs:
SQL5024
Message Text: Host variable &1 not character, UCS-2 graphic, or UTF-16 graphic.
Cause Text: Host variable &1 is not defined as character, UCS-2 graphic, or UTF-16 graphic. Host
variables in a precompiled program or REXX procedure must be character, UCS-2 graphic,
or UTF-16 graphic if used as:
v The statement string in a PREPARE or EXECUTE IMMEDIATE statement.
v The table name in a DESCRIBE TABLE statement.
v The procedure name in a CALL statement.
v The server name, authorization name, or password in a CONNECT, SET CONNECTION,
RELEASE, DISCONNECT, SET ENCRYPTION PASSWORD, or SET SESSION
AUTHORIZATION statement.
v The special register value in a SET special register statement such as SET PATH or SET
SCHEMA.
v The SQLSTATE value or signal information value in a SIGNAL statement.
v A descriptor name.
Recovery Text: Specify a host variable that is character, UCS-2 graphic, or UTF-16 graphic. Try the request
again.
SQLCODE or -5024
SQLCODEs:
SQLSTATE or 42618
SQLSTATEs:
SQL5027
Message Text: OPTION(*SYS) valid only if relational database &1 (product identification &2) is an iSeries.
Cause Text: SQL naming is required when the create of a SQL package is to a relational database that is
not another iSeries.
Recovery Text: Change the program to use SQL naming, then retry the CRTSQLxxx command with the
parameter OPTION(*SQL).
SQLCODE or -5027
SQLCODEs:
SQLSTATE or 560C4
SQLSTATEs:
SQL5047
Message Text: Error processing SRTSEQ or LANGID parameter. Message is &3, &4.
Cause Text: An error occurred during an attempt to retrieve the sort sequence table for the SRTSEQ
parameter &1 and LANGID parameter &2. Message &3 was returned.
Recovery Text: Correct the errors as indicated by message &3 and issue the request again. If a sort
sequence table is not required, specify *HEX as the SRTSEQ parameter.
SQLCODE or -5047
SQLCODEs:
SQLSTATE or 42616
SQLSTATEs:
SQL5051
Message Text: Qualifier &1 not same as name &2.
Cause Text: One of the following has occurred:
v An object created in a CREATE SCHEMA statement is qualified by a name other than the
schema name. All objects created in a CREATE SCHEMA statement must be either
qualified by the schema name &2 or not qualified. Unqualified objects are implicitly
qualified by the schema name.
v A constraint name was qualified by a name that is not the same as the qualifier for the
table. A constraint for a table must be qualified by the same schema as the table. If not
explicitly qualified, a constraint name is implicitly qualified by the default schema, if one
is specified. Otherwise, the constraint name is implicitly qualified by the authorization ID
for SQL names and by the qualifier of the table name for system names.
Recovery Text: Do one of the following and try the request again:
v Explicitly qualify the object in the schema with &2 or remove qualifier &1 from the object
name.
v Use the same qualification for constraint names and table names.
SQLCODE or -5051
SQLCODEs:
SQLSTATE or 42875
SQLSTATEs:
SQL7001
Message Text: Table &1 in &2 not database file.
Cause Text: SQL processing is only valid for a database file. All other file types are not allowed.
Recovery Text: Make certain that the table and schema names are correct.
SQL7002
Message Text: Override parameter not valid.
Cause Text: An Override Data Base File (OVRDBF) command was issued for one of the files referenced
in the SQL statement. A parameter on the OVRDBF command is not valid for SQL. See
message CPF4276 in the job log for information about which parameter is not valid.
Recovery Text: Delete the override (DLTOVR command). Use the OVRDBF command again without the
parameter that is not valid, if necessary, and then try the operation again.
SQLCODE or -7002
SQLCODEs:
SQLSTATE or 42847
SQLSTATEs:
SQL7003
Message Text: File &1 in &2 has more than one format.
Cause Text: SQL cannot process a file unless it has only one format.
Recovery Text: Make certain that the correct filename was specified. Try the request again.
SQLCODE or -7003
SQLCODEs:
SQLSTATE or 42857
SQLSTATEs:
SQL7006
Message Text: Cannot drop schema &1.
Cause Text: &1 is a schema that is in the library list.
Recovery Text: Remove &1 from the library list before attempting the DROP. Try the request again.
SQLCODE or -7006
SQLCODEs:
SQLSTATE or 55018
SQLSTATEs:
SQL7007
Message Text: COMMIT, ROLLBACK, or SAVEPOINT not valid.
Cause Text: A COMMIT, ROLLBACK, or SAVEPOINT statement was issued, but commitment control is
not active.
Recovery Text: Change the commitment control level *NONE to *CHG, *CS, or *ALL. The SET
TRANSACTION statement can be used to change the isolation level to something other
than *NONE. Try the request again.
SQLCODE or -7007
SQLCODEs:
SQLSTATE or 51009
SQLSTATEs:
SQL7010
Message Text: Logical file &1 in &2 not valid for CREATE VIEW.
Cause Text: Logical file &1 in &2 is specified in the subselect clause of a CREATE VIEW. Views cannot
be created over logical files.
Recovery Text: Remove logical file &1 from the CREATE VIEW statement and try the request again.
SQLCODE or -7010
SQLCODEs:
SQLSTATE or 42850
SQLSTATEs:
SQL7011
Message Text: &1 in &2 not table, view, or physical file.
Cause Text: The SQL statement &3 cannot be performed on a file which is not a table, view, single
format logical file, or physical file.
Recovery Text: Do one of the following:
v Use a control language (CL) command to do the function.
v Select the correct table, view, logical, or physical file.
SQLCODE or -7011
SQLCODEs:
SQLSTATE or 42851
SQLSTATEs:
SQL7017
Message Text: Unable to run statement with specified commit level.
Cause Text: SQL is unable to run the statement with the specified commit level because SQL cannot
register a resource with commitment control.
Recovery Text: See previous messages for more information.
SQLCODE or -7017
SQLCODEs:
SQLSTATE or 42971
SQLSTATEs:
SQL7018
Message Text: COMMIT HOLD or ROLLBACK HOLD not allowed.
Cause Text: COMMIT HOLD or ROLLBACK HOLD was attempted to an application server or from an
application requester that is not an iSeries. HOLD is only allowed when the application
requester and the application server are both iSeries.
Recovery Text: Remove HOLD and submit the statement again.
SQLCODE or -7018
SQLCODEs:
SQL7020
Message Text: SQL package creation failed.
Cause Text: An SQL package must exist on the application server to run SQL statements. Creation of a
package for this purpose failed on the application server and returned SQLCODE &1,
SQLSTATE &2. The name of the package being created was &3 in schema &4 on relational
database &5.
Recovery Text: Do the response as indicated for the SQLCODE &1 and SQLSTATE &2. If you are running
with commitment control, exit Interactive SQL or Query Manager and issue a CL COMMIT
or ROLLBACK command. This will enable you to continue processing at the local system.
SQLCODE or -7020
SQLCODEs:
SQLSTATE or 42969
SQLSTATEs:
SQL7021
Message Text: Local program attempting to run on application server.
Cause Text: An attempt was made to run an SQL program in a process that is an application server.
Recovery Text: Initiate another job and run the SQL program in that job.
SQLCODE or -7021
SQLCODEs:
SQLSTATE or 57043
SQLSTATEs:
SQL7022
Message Text: User &1 not the same as current user &2.
Cause Text: One of the following occurred:
v User &1 was specified in a CONNECT statement that specified the local relational
database name. The user specified is not the same as the current job user &2.
v User &1 was specified in a CONNECT statement and a connection using &2 already
exists to the specified relational database using connection method *DUW.
Recovery Text: If connecting to the local relational database, change the statement so the user specified on
the CONNECT is the same as the current job user ID. If connecting to a remote relational
database, either use the SET CONNECTION statement to use the existing connection or end
the current connection and issue the CONNECT statement with the new user id.
SQLCODE or -7022
SQLCODEs:
SQLSTATE or 42977
SQLSTATEs:
SQL7024
Message Text: CCSIDs are not compatible.
SQL7026
Message Text: Auxiliary storage pool &4 or &5 not found.
Cause Text: Object &1 in &2 type *&3 was not created because auxiliary storage pool (ASP) &4 or
device name &5 does not exist on the system or in the ASP group of the thread.
Recovery Text: Specify a correct ASP number or ASP device name and try the request again.
SQLCODE or -7026
SQLCODEs:
SQLSTATE or 42896
SQLSTATEs:
SQL7027
Message Text: Cannot GRANT specified privileges on object &1 in &2 type *&3.
Cause Text: A GRANT operation was attempted on view &1 in &2 type *&3. This operation cannot be
performed because it would give the user specified additional privileges to the underlying
file &4 in &5. The user has *OBJOPR or *OBJMGT system privileges to the underlying file.
Recovery Text: One of the following may be done:
v Grant the specified privileges to &4
v Obtain the required authority from either the security officer or the object owner
v Delete the current authority to &4. Try the operation again.
SQLCODE or -7027
SQLCODEs:
SQLSTATE or 42984
SQLSTATEs:
SQL7028
Message Text: Owner and primary group cannot be the same.
Cause Text: While attempting to create an object, SQL attempted to change the owner of the object. The
new owner was the same as the primary group for that object. This is not allowed.
Recovery Text: Change the primary group for the user profile and try the request again.
SQLCODE or -7028
SQLCODEs:
SQLSTATE or 42944
SQLSTATEs:
SQL7030
Message Text: Alias &1 for table &2 in &3 not valid for statement.
Cause Text: The SQL statement cannot be performed on alias &1 because the alias refers to a member of
table &2 in schema &3.
Recovery Text: Specify a valid table or an alias that does not refer to a member. Try the request again.
SQLCODE or -7030
SQLCODEs:
SQLSTATE or 55042
SQLSTATEs:
SQL7031
Message Text: Sort sequence table &1 too long.
Cause Text: Sort sequence table &1 in &2 is a UCS-2 sort sequence table that is greater than 31560 bytes
long. It cannot be used with Distributed Relational Database Architecture (DRDA).
Recovery Text: Specify a different sort sequence table to be used with Distributed Relational Database
Architecture (DRDA).
SQLCODE or -7031
SQLCODEs:
SQLSTATE or 54044
SQLSTATEs:
SQL7032
Message Text: SQL procedure, function, or trigger &1 in &2 not created.
Cause Text: SQL procedure, function, or trigger &1 in &2 was not created. The compile was not
successful. SQL creates an SQL procedure, function, or trigger as a C program that contains
embedded SQL. Errors not found during the initial parsing of the CREATE PROCEDURE,
ALTER PROCEDURE, CREATE FUNCTION, or CREATE TRIGGER statement can be found
during the precompile.
Recovery Text: If a compile error occurred, see the appropriate listing in QSYSPRT. If the SQL precompile
failed, there is always a listing with the error. If the C compile failed, the listing is only
created if requested. Specify SET OPTION OUTPUT=*PRINT prior to the routine body in
the CREATE statement if listings are required.
SQLCODE or -7032
SQLCODEs:
SQL7033
Message Text: Alias name &1 in &2 not allowed.
Cause Text: Alias name &1 cannot be used. This program was compiled on a release before alias names
were supported. The table name it is using has now been defined as an alias name.
Recovery Text: Recompile the program on a release that supports alias names or remove the alias from the
system.
SQLCODE or -7033
SQLCODEs:
SQLSTATE or 42923
SQLSTATEs:
SQL7034
Message Text: LOB locators are not allowed with COMMIT(*NONE).
Cause Text: A LOB locator cannot be used with commitment control level of *NONE or *NC.
Recovery Text: Use a commitment control level of *CHG, *UR, *CS, *ALL, *RS, or *RR.
SQLCODE or -7034
SQLCODEs:
SQLSTATE or 42926
SQLSTATEs:
SQL7036
Message Text: System User-Defined Type name used in SQLDA.
Cause Text: A User-Defined Type name returned in the extended SQLVAR entry of the SQLDA is longer
than 19 characters. Since there is not room in the SQLNAME entry, the system name is
substituted instead. The system name is 10 characters.
Recovery Text:
SQLCODE or +7036
SQLCODEs:
SQLSTATE or 01634
SQLSTATEs:
SQL7037
Message Text: Data in a distributed file &1 in &2 cannot be redistributed.
Cause Text: An attempt was made to change the node group, partitioning file, partitioning key, or an
attribute of a partitioning key. These changes can cause data to be redistributed, but data in
file &1 in &2 cannot be redistributed because it contains a DataLink with FILE LINK
CONTROL.
Recovery Text: Change the request so that data will not be redistributed, and try the function again.
SQLCODE or -7037
SQLCODEs:
SQLSTATE or 429B6
SQLSTATEs:
SQL7048
Message Text: Operation not allowed because trigger is invalid.
Cause Text: An open of an SQL table or view failed as a result of inoperative trigger &1 in schema &2.
The open could be due to an insert, update, delete, or open cursor statement.
Recovery Text: Drop and re-create trigger &1 in &2. See the previous CPF418A escape message for the
name of the file that failed to open. Preceding the CPF418A will be CPD502B messages for
each invalid trigger found. The SYSTRIGGERS catalog can also be used to determine the
SQL table an invalid trigger is attached to.
SQLCODE or -7048
SQLCODEs:
SQLSTATE or 51037
SQLSTATEs:
SQL7049
Message Text: An internal object limit has been exceeded.
Cause Text: The SQL statement cannot be run successfully because an internal object limitation has been
encountered. The reason code is &1. The operation failed for one of the following reasons: 1
- The maximum number of stored procedures with open result sets has been exceeded. 2 -
An internal space limitation has been reached while processing result sets. 3 - A limit has
been reached creating the C program for an SQL procedure, function, or trigger. 4 - An
internal limit on SQL program or package size has been reached. &2 in &3 type *&4
reached the limit.
Recovery Text: The reason codes and their recovery follow: 1 - Either fetch a result set or close an open
result set for a stored procedure. 2 - Fetch or close one or more open result sets, or reduce
the size of the array result set. 3 - Modify the SQL routine by reducing the number of SQL
statements. 4 - Reduce the number of SQL statements in the program or package or move
some SQL statements to a different module, and recompile the program or package.
SQLCODE or -7049
SQLCODEs:
SQLSTATE or 54035
SQLSTATEs:
SQL7050
Message Text: Result sets are not available from procedure &1 in &2.
Cause Text: An SQL CALL statement was performed for procedure &1 in &2. It opened &3 result sets,
but all were closed before they could be processed. This can be caused by the ending of an
activation group, or by some other function that closes SQL cursors, such as a Reclaim
Resources (RCLRSC) CL command. This can also happen if the procedure contains a SET
RESULT SETS statement, and an error occurred on that statement.
SQL7051
Message Text: MODE DB2SQL before trigger converted to MODE DB2ROW.
Cause Text: MODE DB2SQL before triggers are not supported. The SQL trigger &1 in &2 will be
converted from MODE DB2SQL to MODE DB2ROW.
Recovery Text: MODE DB2ROW should be specified for all BEFORE triggers. Change the statement and
try the request again.
SQLCODE or +7051
SQLCODEs:
SQLSTATE or 01647
SQLSTATEs:
SQL7052
Message Text: Object &1 type *&3 cannot be created in &2.
Cause Text: An attempt to create object &1 type *&3 in &2 failed because the library is not valid for
user objects.
Recovery Text: Perform the operation using a different library.
SQLCODE or -7052
SQLCODEs:
SQLSTATE or 55050
SQLSTATEs:
SQL7053
Message Text: Relational database directory not available.
Cause Text: An attempt to connect to relational database (RDB) &1 failed because the RDB directory is
not available. A vary on operation may be in progress for the Auxiliary Storage Pool (ASP)
devices.
Recovery Text: If a vary on operation is in progress for any ASP devices, wait until the operation is
complete. If repeated attempts fail, you may need to run the command RCLSTG
SELECT(*DBXREF).
SQLCODE or -7053
SQLCODEs:
SQLSTATE or 57011
SQLSTATEs:
|| SQL7054
| Message Text: The open failed due to exit program &1.
SQL7905
Message Text: Table &1 in &2 created but was not journaled.
Cause Text: The table &1 was created in &2, but the table was not journaled. Either a QDFTJRN data
area indicated that journaling should not be started, the default journal did not exist, or the
default journal did exist but the journaling could not be started. The default journal may be
damaged, unable to accept journal entries, or may not exist. The SQL name for the table is
&1 and the system name for the table is &3. For a distributed table, journaling could not be
started on all of the systems. The default journal must exist, and be able to accept journal
entries, on each of the systems in the node group.
Recovery Text: The table was created, but until the table is journaled, COMMIT(*CHG), COMMIT(*CS),
COMMIT(*RS), COMMIT(*RR), COMMIT(*UR), and COMMIT(*ALL) will not be allowed
for table &1. If the default journal does not exist, create the journal (CRTJRN command)
and start journaling (STRJRNPF command). If the journal is in error, correct the problem to
the journal If the table is distributed, correct the problems on all the systems in the node
group and start journaling (STRJRNPF command).
SQLCODE or +7905
SQLCODEs:
SQLSTATE or 01567
SQLSTATEs:
SQL7909
Message Text: Routine &1 was created, but cannot be saved and restored.
SQL7941
Message Text: Application process not at a commit boundary.
Cause Text: A commitment control level other than *NONE was specified on the RUNSQLSTM
command, but the application process is not at a commit boundary.
Recovery Text: Issue a COMMIT or ROLLBACK to get to a commit boundary, or specify
COMMIT(*NONE) on the RUNSQLSTM command.
SQLCODE or -7941
SQLCODEs:
SQLSTATE or 42981
SQLSTATEs:
Related concepts
“SQL message concepts” on page 23
SQL messages are displayed when a DB2 Universal Database for iSeries returns an error or warning
code to the application that uses it.
IBM may not offer the products, services, or features discussed in this document in other countries.
Consult your local IBM representative for information on the products and services currently available in
your area. Any reference to an IBM product, program, or service is not intended to state or imply that
only that IBM product, program, or service may be used. Any functionally equivalent product, program,
or service that does not infringe any IBM intellectual property right may be used instead. However, it is
the user’s responsibility to evaluate and verify the operation of any non-IBM product, program, or
service.
IBM may have patents or pending patent applications covering subject matter described in this
document. The furnishing of this document does not grant you any license to these patents. You can send
license inquiries, in writing, to:
IBM Director of Licensing
IBM Corporation
North Castle Drive
Armonk, NY 10504-1785
U.S.A.
For license inquiries regarding double-byte (DBCS) information, contact the IBM Intellectual Property
Department in your country or send inquiries, in writing, to:
IBM World Trade Asia Corporation
Licensing
2-31 Roppongi 3-chome, Minato-ku
Tokyo 106-0032, Japan
The following paragraph does not apply to the United Kingdom or any other country where such
provisions are inconsistent with local law: INTERNATIONAL BUSINESS MACHINES CORPORATION
PROVIDES THIS PUBLICATION “AS IS” WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Some
states do not allow disclaimer of express or implied warranties in certain transactions, therefore, this
statement may not apply to you.
This information could include technical inaccuracies or typographical errors. Changes are periodically
made to the information herein; these changes will be incorporated in new editions of the publication.
IBM may make improvements and/or changes in the product(s) and/or the program(s) described in this
publication at any time without notice.
Any references in this information to non-IBM Web sites are provided for convenience only and do not in
any manner serve as an endorsement of those Web sites. The materials at those Web sites are not part of
the materials for this IBM product and use of those Web sites is at your own risk.
IBM may use or distribute any of the information you supply in any way it believes appropriate without
incurring any obligation to you.
Licensees of this program who wish to have information about it for the purpose of enabling: (i) the
exchange of information between independently created programs and other programs (including this
one) and (ii) the mutual use of the information which has been exchanged, should contact:
IBM Corporation
Such information may be available, subject to appropriate terms and conditions, including in some cases,
payment of a fee.
| The licensed program described in this information and all licensed material available for it are provided
| by IBM under terms of the IBM Customer Agreement, IBM International Program License Agreement,
| IBM License Agreement for Machine Code, or any equivalent agreement between us.
Any performance data contained herein was determined in a controlled environment. Therefore, the
results obtained in other operating environments may vary significantly. Some measurements may have
been made on development-level systems and there is no guarantee that these measurements will be the
same on generally available systems. Furthermore, some measurements may have been estimated through
extrapolation. Actual results may vary. Users of this document should verify the applicable data for their
specific environment.
Information concerning non-IBM products was obtained from the suppliers of those products, their
published announcements or other publicly available sources. IBM has not tested those products and
cannot confirm the accuracy of performance, compatibility or any other claims related to non-IBM
products. Questions on the capabilities of non-IBM products should be addressed to the suppliers of
those products.
All statements regarding IBM’s future direction or intent are subject to change or withdrawal without
notice, and represent goals and objectives only.
All IBM prices shown are IBM’s suggested retail prices, are current and are subject to change without
notice. Dealer prices may vary.
This information is for planning purposes only. The information herein is subject to change before the
products described become available.
This information contains examples of data and reports used in daily business operations. To illustrate
them as completely as possible, the examples include the names of individuals, companies, brands, and
products. All of these names are fictitious and any similarity to the names and addresses used by an
actual business enterprise is entirely coincidental.
COPYRIGHT LICENSE:
This information contains sample application programs in source language, which illustrate programming
techniques on various operating platforms. You may copy, modify, and distribute these sample programs
in any form without payment to IBM, for the purposes of developing, using, marketing or distributing
application programs conforming to the application programming interface for the operating platform for
which the sample programs are written. These examples have not been thoroughly tested under all
conditions. IBM, therefore, cannot guarantee or imply reliability, serviceability, or function of these
programs.
Each copy or any portion of these sample programs or any derivative work, must include a copyright
notice as follows:
© (your company name) (year). Portions of this code are derived from IBM Corp. Sample Programs. ©
Copyright IBM Corp. _enter the year or years_. All rights reserved.
If you are viewing this information softcopy, the photographs and color illustrations may not appear.
Trademarks
The following terms are trademarks of International Business Machines Corporation in the United States,
other countries, or both:
| DB2
| DB2 Universal Database
| Distributed Relational Database Architecture
| DRDA
| IBM
| IBM (logo)
| iSeries
| OS/390
| System i
| z/OS
Java and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other
countries, or both.
Other company, product, and service names may be trademarks or service marks of others.
Personal Use: You may reproduce these publications for your personal, noncommercial use provided that
all proprietary notices are preserved. You may not distribute, display or make derivative works of these
publications, or any portion thereof, without the express consent of IBM.
Commercial Use: You may reproduce, distribute and display these publications solely within your
enterprise provided that all proprietary notices are preserved. You may not make derivative works of
these publications, or reproduce, distribute or display these publications or any portion thereof outside
your enterprise, without the express consent of IBM.
Except as expressly granted in this permission, no other permissions, licenses or rights are granted, either
express or implied, to the publications or any information, data, software or other intellectual property
contained therein.
IBM reserves the right to withdraw the permissions granted herein whenever, in its discretion, the use of
the publications is detrimental to its interest or, as determined by IBM, the above instructions are not
being properly followed.
You may not download, export or re-export this information except in full compliance with all applicable
laws and regulations, including all United States export laws and regulations.
Printed in USA