<-- Back

Error: could not create unique index key (taskid)=(0) is duplicated while deploying an application in Mendix Cloud

Issue

The application deployment failed, and upon reviewing the application logs, the following error was encountered:

Caused by: org.postgresql.util.PSQLException: ERROR: could not create unique index Key (taskid)=(0) is duplicated.

Environment

Applications hosted in Mendix Cloud

Cause

The issue arises due to a unique index constraint on the taskid. When deploying the application, the index creation process fails because multiple rows contain the same taskid value, which is not allowed under a unique index constraint. This typically results from data inconsistencies in the database or a misconfiguration in the domain model. 

Solution/Workaround

To resolve this issue, follow these steps:

  1. Clear the database. This ensures the unique index can be created successfully without conflicts during deployment.
  2. Recreate the database structure by redeploying the application.
  3. Restore a backup

 

Internal information related

  • 239373
  • CLDOPS-14443

 

Additional information 

Mendix Documentation

 

 

Have more questions? Submit a request

0 Comments

Article is closed for comments.

To provide feedback, please open a ticket here. Don't forget to include the article's URL along with the feedback you would like to provide.