PR_DATA_RESTORE_PK constraint error installing hot fix
While installing a hot fix a unique constraint error was generated during the installation. When the finish button was clicked, the hotfix appears to be fully installed and committed, even though the commi checkbox was not selected.
Hotfix Installation encountered an error:
Could not save rollback information for an installed hotfix: ORA-00001: unique constraint (PEGA_RULES718.PR_DATA_RESTORE_PK) violated
Steps to Reproduce
Unknown. Hot fixes install successfully in lower environments.
A defect or configuration issue in the operating environment. The upgrade procedure followed which used a database specific tool to migrate the upgraded rules schema to higher environment instead of the migrate script that comes with the media. This resulted in the PYLASTRESERVEDID value for DATA-UNIQUEID !HOTFIXORDER- in the pc_data_uniqueid table to be out of sync with the content of the pr_data_products and pr_data_restore tables.
Make the following change to the operating environment:
Truncate the pr_data_products and pr_data_restore tables. This will result in all currently installed hot fixes being in a committed state and will allow any future hot fixes to be installed, and be able to be committed or rolled back, without issue.
Update processes to avoid this type of issue in the future:
1. Hot fixes should be installed, tested, and then either committed or rulled back. Adding new hot fixes on top of uncommitted hot fixes is not a recommended practice.
2. When migrating from a lower to higher environment all hot fixes should be committed in lower environment before you migrate. If database specific tools are used to migrate and not the migrateSystems script that comes with the media truncate the pr_data_products and pr_data_restore tables in the higher environments after the migration.
Published February 13, 2016 - Updated October 8, 2020
0% found this useful
Have a question? Get answers now.
Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.