You need to sign in to do that
Don't have an account?
Baron Bort
Query for existing records
I have a Salesforce environment deployed and it also contains data. I need to import some additional data into Accounts and Contacts, but I have reason to believe that the .csv that I need to use for the import contains records that already exist in Salesforce.
Let's assume that users have already made changes to some of the existing records, so I don't want to override any changes by using an Upsert.
I'm using Jitterbit to perform this insert operation. So far I've tried to grab a sample set of contact names from my .csv in my [SELECT Id, Name FROM Contact ...] query. The problem is that Jitterbit reports that no records are returned, when I know that some of the contact names do exist in Salesforce because I checked a few manually.
Jitterbit uses this particular query:
but it returns 0 results.
I tried:
but that returned 0 results as well.
Is there some way for me to check multiple Contact/Account names in a single query so I can confirm which records exist already or not? (My import files go into the 1000s)
Let's assume that users have already made changes to some of the existing records, so I don't want to override any changes by using an Upsert.
I'm using Jitterbit to perform this insert operation. So far I've tried to grab a sample set of contact names from my .csv in my [SELECT Id, Name FROM Contact ...] query. The problem is that Jitterbit reports that no records are returned, when I know that some of the contact names do exist in Salesforce because I checked a few manually.
Jitterbit uses this particular query:
SELECT Id, Name FROM Contact WHERE Name like '%Person 1,Person 2,Person 3%'
but it returns 0 results.
I tried:
... WHERE Name IN ('Person 1', 'Person 2', 'Person 3')
but that returned 0 results as well.
Is there some way for me to check multiple Contact/Account names in a single query so I can confirm which records exist already or not? (My import files go into the 1000s)
Otherwise, you could create an external id field for your Contact record, then update the existing data to populate that external id (E.g. based on a unique criteria.. perhaps your contacts have unique email addresses or something), and then you could use the same external id criteria in your CSV file to perform an Upsert of the data.
To answer your query question though, this should work for a small subset of contacts, but once you go several contact names, it's going to get expensive..