Message Reference

SQL0600 - SQL0699

SQL0600NA routine "<routine-name>" could not be generated because of a duplicate signature or because it would override an existing routine.

Explanation: During the CREATE or ALTER operation, a system-generated cast function, observer method, mutator method, or constructor function could not be created because another function or method with the same name and signature already exists in the schema, or because the method or function would override an existing method.

User Response: Choose another name for the user-defined type, attribute, or cast function that causes the conflict, or drop the function or method with the same name as the function or method that could not be generated.

sqlcode: -600

sqlstate: 42710

SQL0601NThe name of the object to be created is identical to the existing name "<name>" of type "<type>".

Explanation: The CREATE or ALTER statement tried to create or add an object "<name>" when an object of type "<type>" already exists with that name on the application server or in the same statement.

If "<type>" is FOREIGN KEY, PRIMARY KEY, UNIQUE, or CHECK CONSTRAINT, the "<name>" is the constraint name specified in the CREATE or ALTER TABLE statement or generated by the system.

Federated system users: some data sources do not provide the appropriate values for the "<name>" and "<type>" message tokens. In these cases, "<name>" and "<type>" will have the following format: "OBJECT:<data source> TABLE/VIEW", and "UNKNOWN" indicating that the actual values at the specified data source are not known.

The statement cannot be processed. No new object is created, and the existing object is not altered or modified.

User Response: Either drop the existing object or choose another name for the new object.

Federated system users: if the statement is a CREATE FUNCTION MAPPING or a CREATE TYPE MAPPING statement, the user can also consider not supplying a type mapping name and the system will automatically generate a unique name for this mapping.

sqlcode: -601

sqlstate: 42710

SQL0602NThe CREATE INDEX or CREATE INDEX EXTENSION statement specifies too many columns (16 is the maximum).

Explanation: The number of columns for the index that would be generated by the CREATE INDEX statement exceeds the maximum of 16 columns for the database manager. If the index is defined on a typed table, there is additional overhead that reduces the maximum number of specified columns to 15.

For a CREATE INDEX EXTENSION statement, the GENERATE KEY function returns a number of columns that exceeds the maximum of 16 columns allowed in an index.

Federated system users: the limit for other data sources is different. That limit could have been exceeded. This problem may be detected on the federated server, or it may be detected on the data source.

The statement cannot be processed.

User Response: Change the index definition to conform to the column limit of 16. For a CREATE INDEX EXTENSION statement, specify a different GENERATE KEY function, or redefine the function to return fewer columns.

Federated system users: change the index definition to conform to the column limit for the data source.

sqlcode: -602

sqlstate: 54008

SQL0603NA unique index cannot be created because the table contains rows which are duplicates with respect to the values of the identified columns.

Explanation: The index defined in the CREATE INDEX statement could not be created as unique, because the specified table already contains rows that duplicate the values of the identified columns.

Federated system users: this situation may also be detected by the data source.

The statement cannot be processed. The specified index is not created.

User Response: Examine the data to determine if the duplicate data is permitted. Alternatively, consider creating a non-UNIQUE index.

sqlcode: -603

sqlstate: 23515

SQL0604NThe length, precision, or scale attribute for column, distinct type, structured type, attribute of structured type, function, or type mapping "<data-item>" is not valid.

Explanation: There is an error in the data type specification in a CREATE or ALTER statement, or a CAST specification. An invalid length, precision or scale attribute may have been specified, or it may be that the data type itself is incorrect or not permitted in this context. The location of the error is given by "<data-item>" as follows:

Federated system users: if the statement is a CREATE TYPE MAPPING statement, an attempt was made to create a type mapping where a type attribute for either the local data type or the remote data type is not valid. Possible reasons include:

The statement cannot be processed.

User Response: Correct the syntax and try again.

sqlcode: -604

sqlstate: 42611

SQL0605WThe index was not created because the index "<name>" already exists with the required description.

Explanation: A CREATE INDEX operation attempted to create a new index and the indicated index matches the required index.

For CREATE INDEX, two index descriptions match if they identify the same columns in the same order with the same ascending or descending specifications, and are both specified as unique or the new index is specified as non-unique. Also, two index descriptions match if they identify the same columns in the same order with the same or reverse ascending or descending specifications, and at least one description includes the ALLOW REVERSE SCANS parameter.

The new index was not created.

User Response: No action is required unless the existing index "<name>" is not a suitable index. For example, the existing index "<name>" is not a suitable index if it does not allow reverse scans, and the required one does (or vice versa). In this case, the index "<name>" must be dropped before the required index can be created.

sqlcode: +605

sqlstate: 01550

SQL0606NThe COMMENT ON or LABEL ON statement failed because the specified table or column is not owned by "<owner>".

Explanation: An attempt was made to comment or label on a table or column which does not exist or is not owned by the owner specified in the message text.

Processing of the SQL statement has ended.

User Response: Correct the statement. Try again.

sqlcode: -606

sqlstate: 42505

SQL0607N"<operation>" is not defined for system objects.

Explanation: The "<operation>" specified in the SQL statement cannot be performed on system objects. One of the following was attempted:

The statement cannot be processed.

User Response: Do not attempt to modify any system objects except for those columns of the system catalog tables which are updateable through updateable SYSSTAT views. See the SQL Reference for more information.

sqlcode: -607

sqlstate: 42832

SQL0612N"<name>" is a duplicate name.

Explanation: A statement was issued with the same name appearing more than once where duplicates are not allowed. Where these names appear varies depending on the type of statement.

The statement cannot be processed.

User Response: Specify unique names as appropriate for the type of statement.

sqlcode: -612

sqlstate: 42711

SQL0613NThe primary key or a unique key identified by "<name>" is too long or has too many columns.

Explanation: The sum of the internal lengths of columns in the PRIMARY KEY clause or a UNIQUE clause identified by "<name>" exceeds 1024 or the number of columns exceeds the maximum of 16. Also, a primary key or a unique key cannot be defined using a LONG VARCHAR column. If the primary key or unique constraint is defined on a typed table, there is additional index overhead that reduces the maximum number of specified columns to 15 and limits the length to 1020.

"<name>" is the constraint name, if specified, of the primary key or unique constraint. If a constraint name was not specified, "<name>" is the first column name specified in the primary key or unique constraint clause followed by three periods.

The statement cannot be processed.

User Response: Modify the primary key or a unique key definition by eliminating one or more key columns to conform to the column limit of 16 and the key length limit.

sqlcode: -613

sqlstate: 54008

SQL0614NThe index or index extension "<index-name>" cannot be created or altered because the combined length of the specified columns is too long.

Explanation: The index could not be created or altered because the sum of the key column internal lengths would exceed 1024. Also, an index cannot be created using a LONG VARCHAR, LONG VARGRAPHIC, or LOB column. If the index is defined on a typed table, there is additional index overhead that reduces the maximum length by 4 bytes. The index may be altered by an ALTER TABLE statement that alters the data type of one or more columns.

An index extension could not be created because the sum of the columns returned by the GENERATE KEY function would exceed 1024.

The statement cannot be processed. The specified index or index extension was not created or the table could not be altered.

User Response: To modify the index definition or alter column, eliminate one or more key columns and reduce the key length to the permitted maximum. For an index extension definition, specify a different GENERATE KEY function, or redefine the function to reduce the length of the returned row.

sqlcode: -614

sqlstate: 54008

SQL0615NThe object "<object-name>" of type "<object-type>" cannot be dropped because it is currently in use by the same application process.

Explanation: A DROP statement of an object cannot be issued when it is in use.

The statement cannot be processed. The object is not dropped.

User Response: Close any cursors that depend either directly or indirectly on the object "<object-name>" and resubmit the statement.

sqlcode: -615

sqlstate: 55006

SQL0620NThe CREATE TABLE statement failed because "<user-id>" has no private, recoverable dbspaces with less than 255 tables.

Explanation: The dbspace name was not specified in the CREATE TABLE statement, so the database manager tried to find a private dbspace owned by "<user-id>". This message will appear under one of the following conditions:

  1. There were no private dbspaces found in the DB2 for VM database for the "<user-id>".
  2. There were one or more private dbspaces found for the "<user-id>", but each contained 255 tables.
  3. The private dbspaces were located in nonrecoverable storage pools. Only private dbspaces that exist in recoverable storage pools will be available when the CREATE TABLE statement does not specify the dbspace name.

Processing of the SQL statement has ended.

User Response: Suggestions for the three conditions above are:

  1. Acquire a private dbspace in a recoverable storage pool. You may require a database administrator's assistance.
  2. Drop a table in a private dbspace residing in a recoverable storage pool to free up an entry, or take the action indicated in (1) above.
  3. If you want to create the table in a dbspace existing in a non-recoverable storage pool, then specify the dbspace name on the CREATE TABLE command. Otherwise, take the action indicated in (1) above.

Then rerun the CREATE TABLE statement.

If appropriate, acquire a private dbspace for the user.

sqlcode: -620

sqlstate: 57022

SQL0623NA clustering index already exists on table "<name>".

Explanation: The CREATE INDEX statement would create a second clustering index on the specified table. A given table can have only one clustering index.

The statement cannot be executed.

User Response: Check to determine the identity and validity of the existing clustering index on table "<name>". Consider creating the index without the CLUSTER attribute.

sqlcode: -623

sqlstate: 55012

SQL0624NTable "<name>" already has a "<key-type>" key.

Explanation: A primary key or partitioning key cannot be defined in an ALTER TABLE statement because the indicated table already has a key of this type.

The statement cannot be executed.

User Response: A table cannot have more than one primary key or partitioning key.

sqlcode: -624

sqlstate: 42889

SQL0628NMultiple or conflicting keywords involving the "<clause-type>" clause are present.

Explanation: There are several possible reasons why this condition might have been diagnosed for the statement. Exactly which one happened is indicated by the value of "<clause-type>". The possibilities to consider are:

User Response: Check that the statement conforms to the syntax and rules defined for the statement. Correct any invalid occurrences of duplicate or conflicting keywords.

sqlcode: -628

sqlstate: 42613

SQL0629NSET NULL cannot be specified because FOREIGN KEY "<name>" cannot contain null values.

Explanation: The SET NULL option of the indicated FOREIGN KEY clause is not valid because no column of the key allows null values.

"<name>" is the constraint name, if specified, in the FOREIGN KEY clause. If a constraint name was not specified, "<name>" is the first column name specified in the column list of the FOREIGN KEY clause followed by three periods.

The statement cannot be processed.

User Response: Change either a column of the key to allow null values or change the delete rule.

sqlcode: -629

sqlstate: 42834

SQL0631NFOREIGN KEY "<name>" is too long or has too many columns.

Explanation: The sum of the column internal lengths identified in the FOREIGN KEY clause in a CREATE TABLE statement exceeds 1024, or the number of columns identified exceeds 16. Also, a foreign key cannot be defined using a LONG VARCHAR column.

"<name>" is the constraint name, if specified, in the FOREIGN KEY clause. If a constraint name was not specified, "<name>" is the first column name specified in the column list of the FOREIGN KEY clause followed by three periods.

The statement cannot be processed.

User Response: To modify the foreign key definition, eliminate one or more key columns and conform to the 16 column limit and the key length limit.

sqlcode: -631

sqlstate: 54008

SQL0632NFOREIGN KEY "<name>" is not valid because the table cannot be defined as a dependent of table "<table-name>" because of delete rule restrictions (reason code = "<reason-code>").

Explanation: A referential constraint cannot be defined because the object table of the CREATE TABLE or ALTER TABLE statement cannot be defined as a dependent of table "<table-name>" for one of the following reason codes:

The delete rules of the existing relationships cause an error, not the delete rule specified in the FOREIGN KEY clause of the CREATE TABLE or ALTER TABLE statement.

"<name>" is the constraint name, if specified, in the FOREIGN KEY clause. If a constraint name was not specified, "<name>" is the first column name specified in the column list of the FOREIGN KEY clause followed by three periods.

The statement cannot be processed.

User Response: If possible, eliminate the particular FOREIGN KEY clause from the CREATE TABLE or ALTER TABLE statement.

sqlcode: -632

sqlstate: 42915

SQL0633NThe delete rule of FOREIGN KEY "<name>" must be "<delete-rule>" (reason code = "<reason-code>").

Explanation: The delete rule specified in a FOREIGN KEY clause of the CREATE TABLE or ALTER TABLE statement is not valid. The indicated delete rule is required for one of the following reason codes:

"<name>" is the constraint name, if specified, in the FOREIGN KEY clause. If a constraint name was not specified, "<name>" is the first column name specified in the column list of the FOREIGN KEY clause followed by three periods.

The statement cannot be processed.

User Response: If possible, change the delete rule.

sqlcode: -633

sqlstate: 42915

SQL0634NThe delete rule of FOREIGN KEY "<name>" must not be CASCADE (reason-code = "<reason-code>").

Explanation: The CASCADE delete rule specified in the FOREIGN KEY clause of the CREATE TABLE or ALTER TABLE statement is not valid for one of the following reason codes:

The statement cannot be processed.

User Response: If possible, change the delete rule.

sqlcode: -634

sqlstate: 42915

SQL0637NMore than one PRIMARY KEY clause or more than one DROP PRIMARY KEY clause was specified.

Explanation: The CREATE TABLE statement contains two or more PRIMARY KEY clauses, or the ALTER TABLE statement contains two or more PRIMARY KEY or DROP PRIMARY KEY clauses.

The statement cannot be processed.

User Response: Correct the statement.

sqlcode: -637

sqlstate: 42614

SQL0638NTable "<name>" cannot be created because no column definitions were specified.

Explanation: The CREATE TABLE statement does not contain any column definitions.

The statement cannot be processed.

User Response: Add one or more column definitions to the statement.

sqlcode: -638

sqlstate: 42601

SQL0644NInvalid value specified for keyword "<keyword>" in statement "<statement-type>".

Explanation: The keyword "<keyword>" is followed by an invalid value as allowed by the description of "<statement-type>". For numeric values, the value may be outside a defined range. For other types, the value is not in the defined set of valid values.

User Response: Determine from reference documentation for the "<statement-type>" what are valid values and make the appropriate change.

sqlcode: -644

sqlstate: 42615

SQL0647NBufferpool "<bufferpool-name>" is currently not active.

Explanation: The bufferpool "<bufferpool-name>" is not active in the current database environment. An attempt was made to find another bufferpool with the same page size but there are no such bufferpools active in the current database environment. The bufferpool "<bufferpool-name>" was recently defined but has not yet been activated.

The statement cannot be processed.

User Response: The database must be stopped and started again to activate the required bufferpool.

sqlcode: -647

sqlstate: 57003

SQL0648NThe foreign key cannot be defined because it will cause table "<owner1.table-name1>" to be delete-connected to table "<owner2.table-name2>" through multiple paths. Reason Code = "<reason-code>".

Explanation: The foreign key cannot be defined because one of the following reason codes = "<reason-code>":

01
The relationship will cause table "<owner1.table-name1>" to be delete-connected to table "<owner2.table-name2>" through multiple paths with the same delete rule of SET NULL.

02
The relationship will cause table "<owner1.table-name1>" to be delete-connected to table "<owner2.table-name2>" through multiple paths with different delete rules.

Processing of the SQL statement has ended.

User Response: Correct the statement. Try again.

sqlcode: -648

sqlstate: 42915

SQL0658NThe object "<name>" cannot be explicitly dropped.

Explanation: The identifier "<name>" identifies one of the following:

The statement cannot be processed.

User Response:

sqlcode: -658

sqlstate: 42917

SQL0659NMaximum size of a table object has been exceeded.

Explanation: One or more of the objects which make up a table has reached its maximum size. The storage objects that make up a table are:

Once a storage object has grown to its maximum size, it cannot be extended further.

User Response: To make existing space within the object available to store new data, the following actions may be taken:

sqlcode: -659

sqlstate: 54032

SQL0667NThe FOREIGN KEY "<name>" cannot be created because the table contains rows with foreign key values that cannot be found in the parent key of the parent table.

Explanation: The definition of the indicated foreign key failed because the table being altered contains at least one row where the foreign key does not match the parent key value in the parent table.

"<name>" is the constraint name, if specified. If a constraint name was not specified, "<name>" is the first column name specified in the column list of the FOREIGN KEY clause followed by three periods.

The statement cannot be processed. The specified table is not altered.

User Response: Remove the erroneous table rows and define the foreign key.

sqlcode: -667

sqlstate: 23520

SQL0668NOperation not allowed when the underlying table (or a dependent table) is in the Check Pending state.

Explanation: When a table is in a check pending state, there may be one or more rows that violate constraints defined on the data. This table cannot be used for the operation. An operation on a parent table that is not in a check pending state may also receive this error if a dependent table is in a check pending state.

User Response: Execute the SET INTEGRITY statement with the IMMEDIATE CHECKED option and ensure that the data satisfies all the constraints defined on the table or the table depending on it.

sqlcode: -668

sqlstate: 57016

SQL0669NA system required index cannot be dropped explicitly.

Explanation: The DROP INDEX statement attempted to drop an index required to:

A system required index cannot be dropped using the DROP INDEX statement.

The statement cannot be processed. The specified index is not dropped.

User Response: If you do not want to keep the primary or unique constraint, use the DROP PRIMARY KEY clause or the DROP CONSTRAINT clause of the ALTER TABLE statement to remove the primary key or unique constraint. If the index was created only for enforcing the primary or unique key, then the index will be dropped. If not, the DROP INDEX statement could then be processed.

The index for an OID column can only be dropped by dropping the table.

The index required to maintain a replicated summary table can only be dropped by first dropping the replicated summary table.

sqlcode: -669

sqlstate: 42917

SQL0670NThe row length of the table exceeded a limit of "<length>" bytes. (Regular table space "<tablespace-name>".)

Explanation: The row length of a table in the database manager cannot exceed:

The length is calculated by adding the internal lengths of the columns. Details of internal column lengths can be found under CREATE TABLE in the SQL Reference.

One of the following conditions can occur:

The statement cannot be processed.

User Response: Depending on the cause, do one of the following.

sqlcode: -670

sqlstate: 54010

SQL0673NA primary or unique key index cannot be created because the table contains rows which are duplicates with respect to the values of the identified primary or unique key columns of constraint "<name>".

Explanation: The primary or unique key definition of the constraint identified by "<name>" failed because the table being altered already contains rows with duplicate values for the PRIMARY KEY or UNIQUE clause columns.

"<name>" is the constraint name, if specified. If a constraint name was not specified, "<name>" is the first column name specified in the primary key or unique constraint clause followed by three periods.

The statement cannot be processed. The specified table is not altered.

User Response: Remove the erroneous rows from the table before attempting to define the primary or unique key.

sqlcode: -673

sqlstate: 23515

SQL0680NToo many columns are specified for a table, view, or table function.

Explanation: The maximum number of columns permitted for each table is based on the page size of the table space and the data types of the columns. The limits for tables are:

The actual number of columns for a table is determined by the following formula: Total Columns * 8 + Number of LOB Columns * 12 + Number of Datalink Columns * 28 <= row size limits for page size.

The maximum number of columns permitted for each view is 5000.

The maximum number of columns permitted for a table function is 255.

Federated system users: other data sources may have a different maximum column limit. This limit has been exceeded.

The statement cannot be processed.

User Response: Ensure that the number of table or view columns does not exceed the limit. If creating a table where a larger page size would allow the number of columns, specify a table space with the larger page size. Create separate tables or views, as required, to hold additional information beyond the limit.

Federated system users: limit the number of table columns to the maximum supported by the data source. Create separate tables or views, as required, to hold additional information beyond the maximum number of columns supported by the data source.

sqlcode: -680

sqlstate: 54011

SQL0683NThe specification for column, attribute, user-defined type or function "<data-item>" contains incompatible clauses.

Explanation: There is an error in a data item specification in a CREATE or ALTER. Incompatible specifications are present, such as: "INTEGER and FOR BIT DATA". The location of the error is given by "<data-item>" as follows:

The statement cannot be processed.

User Response: Remove the incompatibility and try the statement again.

sqlcode: -683

sqlstate: 42842

SQL0696NThe definition of trigger "<trigger-name>" includes an invalid use of correlation name or transition table name "<name>". Reason code="<reason-code>".

Explanation: The trigger definition included an invalid use of "<name>". The value of "<reason-code>" indicates the specific problem as follows.

1
NEW correlation name and NEW_TABLE name are not allowed in a DELETE trigger.

2
OLD correlation name and OLD_TABLE name are not allowed in an INSERT trigger.

3
OLD_TABLE name and NEW_TABLE name are not allowed in a BEFORE trigger.

The statement cannot be processed.

User Response: Remove the invalid correlation name or transition table name along with the preceding keyword.

sqlcode: -696

sqlstate: 42898

SQL0697NOLD or NEW correlation names are not allowed in a trigger defined with the FOR EACH STATEMENT clause.

Explanation: The trigger, as defined, includes a REFERENCING clause with OLD or NEW correlation names specified (or both) and the FOR EACH STATEMENT clause. These cannot be specified together.

The statement cannot be processed.

User Response: Remove any OLD or NEW correlation names from the REFERENCING clause or replace FOR EACH STATEMENT with FOR EACH ROW.

sqlcode: -697

sqlstate: 42899


[ Top of Page | Previous Page | Next Page ]