Skip to main content

Error: 'The create unique index statement terminated because a duplicate key was found for the object name dbo.orc_TaskRelations'

What to do if you see a duplicate key error when upgrading Orchestrate.

Written by Arthur Ashdown

You may see the following error when upgrading Orchestrate:

⚠️Error: An unexpected error occurred. Please report this problem to your system administrator with the following information:
​
System.Data.SqlClient.SqlException: 'The create unique index statement terminated because a duplicate key was found for the object name dbo.orc_TaskRelations and the index name IX_orc_TaskRelations. The duplicate key value is (123,456,78). The statement has been terminated.'

This error occurs because duplicate records exist in the dbo.orc_TaskRelations table, which prevents the upgrade from creating a required unique index.


Resolve this error

To resolve this issue, our Support team will need to run scripts directly on your database.

Please raise a new case online and include the following information:

  • The title of this article.

  • The version of Orchestrate you are upgrading from.

  • The version of Orchestrate you are upgrading to.

📌Note: Do not attempt to run any scripts on the database yourself. Our Support team will guide you through the resolution process.

Did this answer your question?