Server Manager - Update Database - Fatal Error - Local base fails to update - Error - Duplicate key value violates unique constraint idx_pmcsubset_name

Purpose (problem description)

This page provides help when the following error is encountered when performing an upgrade on the management database:

ERROR: duplicate key value violates unique constraint “idx_pmcsubset_name” as shown in the screenshot below :

Observed in CAST Version

ReleaseYes/No
8.3

Observed in RDBMS

RDBMSYes/No
CSS

Step by Step Scenario

  1. Upgrade databases from CAST AIP 8.2.x (x<8) to 8.2.y (y>=8) or 8.3
  2. Upgrade fails on the management database with the error: duplicate key value violates unique constraint “idx_pmcsubset_name”

Action Plan

Perform the below actions

  1. This problem appears in version CAST AIP 8.2 (lower than 8.2.8) when we upgrade the management database and the ID of the Analysis Units have been updated in the same format that is in 8.3. To resolve the issue:

    1. Restore the databases before migration

    2. Run the following query on the local database/KB :

DELETE FROM PMC_SUBSET_OBJECTS WHERE Subset_Id IN (SELECT * FROM PMC_SUBSETS WHERE Subset_Name LIKE ‘CMS_%’ );

   3. Run the following query on the local database/KB :

      ```java
DELETE
FROM   PMC_SUBSETS
WHERE  Subset_Name LIKE 'CMS_%';
  1. Run the migration again.
  2. If the above points do not help you, contact CAST Technical Support and provide the Relevant input

 

Relevant Input

Notes/comments

Ticket # 16039

Related Pages