
I’m attempting to import a managed solution from our DEV environment into QA and encountered the following error:
Solution "{solutionName}" failed to import: ImportAsHolding failed with exception: Import failed: Cannot insert duplicate key row in object 'MetadataSchema.EntityRelationship' with unique index 'ndx_for_entitykey_UniqueEntityRelationship'. The duplicate key value is (0, Jan 1 1900 12:00AM, manualsla_{customEntityLogicalName}). The statement has been terminated.
We have enabled SLA on this custom entity and this entity is
Has anyone experienced this issue before or have suggestions on how to resolve it?
Hi saidiev3,
The error you're encountering during solution import:
Cannot insert duplicate key row in object 'MetadataSchema.EntityRelationship'...
is typically caused by a conflict in SLA configurations on a custom entity when importing a managed solution. The key part of the error — (0, Jan 1 1900 12:00AM, manualsla_{customEntityLogicalName}) — suggests that the system is trying to insert a duplicate SLA relationship.
Here are a few steps to resolve it:
Let me know if this helps!
If the answer was useful, please mark it as helpful so others can benefit too. 😊
Best regards,
Daniele Incalza