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
wilbur07wilbur07 

What's the best way?

I have a csv file that Data Loader would handle nicely except that one of the columns in the CSV is called salesperson1 and it has values that are names.  I would like to map this value into Contact.Name but you can't do that in Data Loader.

What I need is to go into sfdc and find out the contact id's that match the names in my csv file and then use that to populate the contact field when I migrate the data from csv to salesforce.

What is the best way to do this?  I'm thinking Talend but I haven't found an easy solution there either.

James
jyotijyoti
I'm not sure this is the best way, but we've done vlookups to find the ContactId.
gireeshzgireeshz
If this is a one-time upload, then jyoti is correct, vlookups with a dump from the object are the quickest way to get the IDs and use them for upload. (Use the magnificent Excel Connector to get the data!)

However, if you are going to set this up for future uploads, even more than just one:

If you think the names are unique enough to pass a match, you could use the Data Loader's UPSERT functionality to automatically pull the SFID from an external field.

Since, IIRC, the 'Name' field of a record cannot be used as an 'External ID' field, you will have to use something else.  What I have done in the past is create another field (call it 'Name_for_upsert') and mark it as an external ID.  Then you will have to copy the values from the 'Name' field into this new field so that you have something to match on (again, 'magnificent Excel Connector').   Then, in the Data Loader, when you setup the UPSERT job tell it to use the 'Name_for_upsert' field to match on.   Link that field to your 'Name' field in the source CSV and the DL will do the job of finding the Object IDs for you.    Keep in mind that you should also have a 'Name_for_Upsert' field in your source CSV as well so that you continue to populate your match field for future uploads.

If there are any that it cannot match or found multiple matches for, they will show up in the errors file.


Hope this helps.