Error "Unique Constraint (**) Violated. The Value ** of The Field ** Already Exist" in a Synchronization When Trying to Update XML File to P6
Last updated on JULY 27, 2017
Applies to:Primavera Gateway - Version 18.104.22.168 to 17.7 [Release 16.2 to 17.7]
Information in this document applies to any platform.
On Gateway when attempting to created a synchronization to import Resource and Role data from XML to P6, it was observed that the synchronization is successful the first time and the Resources and Roles are created correctly.
However it fails when trying to make updates and import the file again (to update Resources) the sync fails with errors saying the Resource and Role IDs already exist.
Name: Unique constraint (ParentObjectId,Name) violated. The value Gateway 01 of the field Name already exists.
STEPS TO REPRODUCE
- Create a synchronization in gateway to import Resource and Role data from XML to P6. The sync is successful the first time to create the Resources and Roles
- Restart the synchronization and try to make updates. The error in the logs state the Role and Resource IDs already exist in P6 which is correct, but the expected behavior should be that the sync should see this and make updates where applicable.
For example changing Resource to Inactive. This sync does have some custom mappings for IsActive standard field and Resource Code Assignments
- Notice the error
Sign In with your My Oracle Support account
Don't have a My Oracle Support account? Click to get started
Million Knowledge Articles and hundreds of Community platforms