2

How do I import data (via csv file) into a custom object in SalesForce and then use identifying fields within the custom object (such as First Name, Last Name, location, etc) to "lookup" and subsequently fill in the SalesForce ID number?

My goal is to relate the custom object's data to the Contact Object without deduping the custom object's data.

I've been able to import data to the Contact Object and the custom object separately. I've also put in a ContactID "lookup" relationship between my Custom Object and my Contact Object. However, the "ContactID" doesn't seem to be populating with the SalesForce ID.

Furthermore, there wasn't really a way for me to list how the lookup would be carried out within the lookup setup.

I've used dataloader.io and chosen to set the lookup by "Full Name" but it still spits out empty boxes in "SalesForce ID."

Thanks!

EDIT - more details / clarification:

I was thinking this might work with a "lookup" function or something else to append a SalesForce ID (instead of an external ID) to a bunch of custom object records that match a Contacts Record through name matching?

An example is that I want to tell SalesForce "If Custom_FirstName1 = Contacts_FirstName1 AND Custom_LastName1 = Contacts_LastName1, Then print Contacts Record 1's SalesForce ID in Custom Object's SalesForceID box"?

My situation is kind of like so:

  • Set 1 = Student Personal Info: First, Last, City
  • Set 2 = Student Grades: First, Last, Course, Grade.

However, there will be multiple rows of information for each student in Set 2 because each student will have taken multiple courses in the semester. I don't have an externalID for either set b/c I wanted to have SalesForce create it for me. Set 1 stays pretty much the same but with a few new student additions (each freshman year), but a new Set 2 is constantly uploaded for each semester.

Is there a way to get SalesForce to fill the unique ID in each row of the grade file for me during upload just using the first name, last name, and email address?

My goal is to not have to prepare the grade file with the unique IDs prior to uploading to SalesForce but to instead have SalesForce match firstname+lastname+email from records already in the Contacts object to then be able to give each grade file record its correct StudentID. I looked around for some formulas to put in the lookup field but that didn't really work either

8/28/13 Edit - Updating What I've Tried Out:

I worked on it with a SalesForce tech support person:

We created a master-detail relationship connecting the contact object to the student grades object. They had me upload the contacts records, which deduped the students (totally fine in this situation). Then they had me export all the Contact records using DataLoader to get the Contact Record IDs for each student. Then I went into Excel and did a vlookup (using "full name") to fill in the contact record ID number for each student grade record. Finally, I uploaded that into the grades object.

I guess my biggest concern is that this process was ok with a 600 grade record file. However, I really don't see it working and at the same time being error-free when I have to upload a 100K or even a 500K grade record file. Is there any way to scale this process for larger datasets in SalesForce? The tech support person said for large files customers usually just send it to SalesForce tech support to upload it.

  • Have you defined an external id on the contact? – Daniel Hoechst Aug 21 '13 at 1:51
  • I've created a field in the Contact Object that I call the "Person ID" which is an "Auto Number" type of ID number that is unique for each contact record. Is that what you meant by an external ID on the contact? – dataprointhemaking Aug 21 '13 at 1:52
  • Not exactly. Look at help.salesforce.com/apex/… – Daniel Hoechst Aug 21 '13 at 1:57
  • Also see blog.jeffdouglas.com/2010/05/07/… – Daniel Hoechst Aug 21 '13 at 1:58
  • Thanks for the links! I guess the External ID route isn't the way for me to go. What would be the best way to "lookup" or somehow append a SalesForce ID (instead of an external ID) to a bunch of custom object records that match a Contacts Record through name matching? Basically, how do I tell SalesForce "If Custom_FirstName1 = Contacts_FirstName1 AND Custom_LastName1 = Contacts_LastName1, Then print Contacts Record 1's SalesForce ID in Custom Object's SalesForceID box"? I've read a couple things on cross-object formulas, but am still lost. – dataprointhemaking Aug 21 '13 at 2:03
1

First define a unique external Id on Contact. This will be a value you define such as student id or some other unique identifying information. If you don't have that, then you could use a concatenation of first name, last name, and email address. When you upload the Student info into contacts, also load the external Id with whatever you've defined as the unique Id for each student.

On the custom object, you want a lookup field to contact. Prepare your grade file so it has the same unique Id for each row. It can be repeated multiple times. You'll then do a second load with the grade information. In dataloader.io, you can define what external Id you want to use to fill the lookup field. Note that you need to perform an Upsert operation to be able to use the External Id.

  • Thanks for putting that together! Is there a way to get SalesForce to fill the unique ID in each row of the grade file for me during upload just using the first name, last name, and email address? My goal is to not have to prepare the grade file with the unique IDs prior to uploading to SalesForce but to instead have SalesForce match firstname+lastname+email from records already in the Contacts object to then be able to give each grade file record its correct StudentID. I looked around for some formulas to put in the lookup field but that didn't really work either. – dataprointhemaking Aug 21 '13 at 22:56
  • No, you need to load the external Id. I think the Jitterbit Data Loader lets you do formulas to concatenate fields. So if your grade data already has the three fields, you can set up your map to do a concatenate. – Daniel Hoechst Aug 22 '13 at 1:25
  • Just for clarification: Do you mean that SalesForce won't automatically match custom object record uploads to already existing Contact records? Meaning that I'll have to do a two-part upload (upload info to Contact Object to upload the Student Contact Info) and upload info to Custom Object (in this example it would be the Student Grades object data). – dataprointhemaking Aug 22 '13 at 20:14
  • It will match existing contact records, but they have to have an external id on them for it to match and you have to specify the external id during the upload process for the grades. – Daniel Hoechst Aug 23 '13 at 3:15
  • I worked on it with a SalesForce tech support person. We created a master-detail relationship connecting the contact object to the student grades object. They had me upload the contacts records, which deduped the students (totally fine in this situation). Then they had me export all the Contact records using DataLoader to get the Contact Record IDs for each student. Then I went into Excel and did a vlookup (using "full name") to fill in the contact record ID number for each student grade record. Finally, I uploaded that into the grades object. – dataprointhemaking Aug 29 '13 at 0:01

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.