You need to sign in to do that
Don't have an account?
Expo
Using External ID's in API calls
Please confirm if we can create and assign tasks to an existing Account in Salesforce.com using API calls and by referencing only the External ID's in such call and not any of the Salesforce.com ID's like Account ID
Based on the example provided below it appears to be possible, but I would like to have it confirmed as I am not familiar with Salesforce.com API's.
public void upsertForeignKeySample() { Opportunity upsertOpportunity = new Opportunity(); upsertOpportunity.setStageName("Prospecting"); //To indicate the reference, attach an Account object, //which has only the external ID field specified. Account upsertParentAccountRef = new Account(); upsertParentAccountRef.setExternal_SAP1_ACCTID__c("SAP111111"); upsertOpportunity.setAccount(upsertParentAccount); //Set the external ID for the Opportunity upsertOpportunity.set_SAP1_OPPID__c("SAP222222"); UpsertResult[] upsertResults = binding.upsert("SAP1_OPPID__c", new SObject[] {upsertOpportunity}); // check results and do more processing after the upsert call ... }
Superfell
Yes, it should be possible.