Start of change

-624   TABLE table-name ALREADY HAS A PRIMARY KEY OR UNIQUE CONSTRAINT WITH SPECIFIED COLUMNS AND PERIODS

Explanation

An ALTER TABLE statement cannot be processed for one of the following reasons:

  • The table already has a primary key.
  • The table has an existing unique constraint with the same definition as the new key. (The existing set of columns and periods is specified in the ALTER statement.)

System action

The statement cannot be processed.

Programmer response

Do not attempt to define a table with more than one primary key, or a unique constraint that duplicates the definition of an existing unique constraint.

SQLSTATE

42889

End of change