Error 2601

Severity Level 14
Message Text

Cannot insert duplicate key row in object '%.*ls' with unique index '%.*ls'.

Explanation

This error occurs when you attempt to put duplicate index values into a column or columns that have a unique index. Microsoft® SQL Server™ does not allow two rows to have the same index value (including NULL) in columns that have a unique index. SQL Server checks for duplicate values when the index is created and each time the table is modified using the INSERT or UPDATE statement.

Action

If you need duplicate index values in the indexed column(s), drop the unique index and create a nonunique index.

To use a unique index on data that contains duplicate values, you must change some values to prevent the duplication. You can change the data already in the table by using the SELECT or UPDATE statement, or you can change the data to be inserted.

See Also
CREATE INDEX INSERT
Creating an Index SELECT
DELETE UPDATE
Errors 2000-2999  

 

  


(c) 1988-98 Microsoft Corporation. All Rights Reserved.