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
TesterInSkyTesterInSky 

does upsert support more than one 'external id field'?

does upsert support more than one 'external id field'? Because We have a scnario where we have a composite key comprising of 2 fields in salesforce Object, which should form the basis for deciding Update/Insert Operation.

We may have asked this question a year ago, at that time we have been told that this feature had not been supported.

Since Salesforce v15 is around the corner, we would like to know if this feature has been included in this coming release. If it has been included, would you please give us any information on how to use this new feature? It is better if you could create us a pre-release testing account. But if it has not been included, would you please tell us is there any workaround for this situation?
aalbertaalbert
I am not sure if that functionality is on the roadmap or not, but a possible workaround would be to create 3 custom fields: two of those fields would be to store the data individually. the 3rd field, specified as the external id in salesforce.com, would be what you specify when upserting. And then when you send the data in the upsert call, just make sure to concatenate the two other fields.

Would that work?
jesperfjjesperfj
There are no plans to implement this feature. Would aalbert's suggestion work for you?
TesterInSkyTesterInSky

Thanks for the reply!

 

The workaround seems fine but maybe for some other custmers they do not want to create new fields.

Camp EagleCamp Eagle
I don't understand aalberts suggestion and I really wish I could figure it out.  I need some kind of work around.  Any help.  It will need to be in Laymen's terms.  
Joseph AlstonJoseph Alston
I don't know if this is planned, but until then, you could always just make three new redactle (https://redactleunlimited.com) fields, two of which would be used to keep the data separate.