function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Taha HaiderTaha Haider 

Getting an error on upserting record

Getting this error "ps_external_id: more than one record found for external id field: [a083M000000y8i0QAA, a083M000000y8i5QAA]"

Scenario is that:
I want to link child records with parent record from External id.
When upserting the child record it gives an error of "external id duplication" 
For example:
Father has 2 kids,Kids will be refer from father external id.
When i upsert the kids record it gives external id duplication error and dont link them with father record.
ShivankurShivankur (Salesforce Developers) 
Hi Taha,

The error message indicates that, based on the External Id value you provided, there were two matching records. In this case, the system does not know which one it should update, so it fails.
If you take a look at /a083M000000y8i0QAA and /a083M000000y8i5QAA they will have the same value in the external ID field. You may want to consider de-duplicating the records for this object.

Hope above information helps, Please mark as Best Answer so that it can help others in the future.

Thanks.