+ Start a Discussion
Ludvig WälimaaLudvig Wälimaa 

Superbadge: Lightning Experience Specialist Challenge 8

Hi,
I finally solved LES Challenge 8 after 10+ hours of headache. I had to create a lot of new columns and add data to the rows in my .CSV-file. Some files contained 130 rows and some only 3 rows. This is a rather small number of rows in guessing and therefore I'm wondering if there's an easier way to solve it when, lets say, you have files with 20 000+ rows. I'm looking for a better way to solve it than how I did it, a best practice of some kind. 
How did you guys do it? Is there a best practice?

I'm using the Dataloader.io when importing: 
  1. Downloaded the Superbadge-Lightning-Import.xlsx and split it up/converted into Explorers.csv , Adventures.csv and OpportunitiesWAdventures.csv 
  2. Insert Explorers from Explorers.csv. 
    1. Since Opportunities contains Adventure Package which contains a lookup to Explorer and the Adventure I figured the easiest would be to start inserting the Explorers.csv. Before inserting the Explorer.csv I had to split the Full Name column into First name and Last name to match the Explorer-object's Firstname and Lastname column. 
  3. Insert Adventures from Adventures.csv
    1. Before importing Adventure.csv I removed the Explorer column since it was empty and I also cleaned up the data in the Description column cause it contained commas and was interfering.
  4. Insert Price Book Entry from Adventures.csv
    1. The Adventures has to be in the Price Book to be able to be added to an Adventure Package. Therefore I added a column in the called PricebookID and added the Pricebook ID of the Standard Price Book to the rows. 
      1. Mapped field:
        1. Adventure Name - Adventure (Lookup via Adventure Name)
        2. List Price - List Price
        3. Active (Adventure) - Active
        4. Pricebookid - Price Book ID
  5. Insert Opportunities from OpportunitiesWAdventures.csv. 
    1. Mapped fields:
      1. Close Date - CloseDate, 
      2. Opportunity Name - Name
      3. Probability (%) - Probability
      4. Quantity - TotalOpportunityQuantity
      5. Stage - StageName
  6. Insert Opportunity Contact Role from OpportunitiesWAdventures.csv
    1. Mapped Fields
      1. Opportunity Name to Opportunity ID(Lookup via  Name) 
      2. Explorer to Explorer (Lookup via Full Name)
  7. Insert Adventure Package from OpportunitiesWAdventures.csv
    1. Added new column for Adventure Name in OpportunitiesWAdventures.csv and added the Adventure name (contained as a part in the Opportunity Name column) to all the rows. 
      1. Mapped Fields: 
        1. Opportunity Name - Opportunity ID(Lookup via Name)
        2. Adventure Name - Price Book Entry ID (Lookup via Adventure Name)
        3. Explorer - Explorer (Lookup via Full Name)
Please leave a comment on how you solved it, thanks! :) 
Trupti Dhoka 32Trupti Dhoka 32
Hello Ludvig,

Thanks for your solution.It helped me to pass challenge.
 
Andreas KarlssonAndreas Karlsson

Hello Mr Wälimaa,

Thank you so much for providing this information! I had a lot of trouble with this step and by reading your very detailed description i managed to solve it.

pavan kumar 177pavan kumar 177
Really you are a life saver.I had completed specialist badge today.But this step irritates me too much.once agian Thanks buddy glad i found your post 
MUSTAPHA ELMADIMUSTAPHA ELMADI

It worked but in the 7th point there is no explorer in the price book record so you need just to map the opportunity and adventure Name.

Thanks

BenTreanorBenTreanor
I'm working through this using dataloader.io. I'm having a problem inserting Price Book Entry. I keep getting the following error: 

"ERROR: insufficient access rights on cross-reference id"

I'm using the .csvs provieded here. Any tips?
Kalyan G.Kalyan G.
@BenTreanor,
You may need to chnage the "Pricebookid" in "Adventures.csv" to the "Id" of "Standard Price Book" in your org. It may be different than the one supplied in the csv, here. The dataloader is trying to connect the Ids and failing.

Let me know if it helped!
BenTreanorBenTreanor
@Kalyan G 3
Thanks for the reply. I guess I'm not sure what you mean. My "Standard Price Book" doesn't have an "Id" that I can find. Can you point me in the direction of this?
Kalyan G.Kalyan G.
@BenTreanor
Check the "Standard Price Book" record in "Price Book".
SELECT Id FROM Pricebook2 WHERE Name = 'Standard Price Book'
Include this Id in your Adventure.csv. under PricebookId column.
BenTreanorBenTreanor
@Kalyan G 3
I did it! Thanks again!
Kalyan G.Kalyan G.
@BenTreanor
Great! All the best ... Just 1 more step and you have the precious 'Lighting Super Badge'!! 
manoj krishnamanoj krishna
Thank you @Ludvig Wälimaa, finally i was able to finish this level after lot of struggle.
however in Step 7 I had to map Quantity and Sales Price  as well 
Ludvig WälimaaLudvig Wälimaa
@Daniel Darugna
I'm not that familiar with the Dataloader Desktop so I don't know how to perform Lookups in that app. Try using the one at www.dataloader.io instead and printscreen if you still having problems. 
Patrick Kelly 73Patrick Kelly 73
Hello all, I keep getting an error that states, "Price Book Entry ID: id value of incorrect type: 01s39000001310wAAA". Does this mean that the data type is not an ID? Rather a name? Also in which object is Pricebook entry, I'm on the very last step and I believe that I am close. Thank you.
rahul singla 9rahul singla 9

It took me 10hrs of research to solve this challenge and find a quick solution: 
Here are my suggestions that could help you complete this in 15mins and save steps.
1. Import Contact, Opportunity and Products (All 3 are independent )
2. there are only 3 records for Products i.e. Adventure so create price book entry manually.
3. Export Contact, Opportunity,Products, Price Book Entry files.
4.  Map the corresponding IDs as mentioned in first post.

NOTE: If it doesnt work , dont waste your time. go to Developer Console , delete the entire data in mentioned objects. Then follow steps again. 

Namita VermaNamita Verma
One more step that is required in this would be to add the 'Role' column to Opportunities Excel sheet and upload the Opportunity Contact Roles as well. Otherwise, it might throw an error.
Patrick McClellanPatrick McClellan
@Ludvig -- thanks for your clear explanation. I've been chasing this one for more than 12 hours, reading all kinds of other instructions, creating csv files with 18 char Id numbers, etc. --all unnecessary!

I'm new to dataloader.io, so it was enlightening in your explanation to understand how to use the lookups to get the Id numbers directly, rather than having to find them and put them in the csv.

Thanks very much. I learned a lot from your explanation, AND I passed the badge.
David DunderdaleDavid Dunderdale
Thanks for the help. I was stuck on Price Book Entry and have now passed the module.
 
Yoma UttadYoma Uttad
LEX Challenge 8 is one of the most frustrating chalenges! I do not understand what is has to do with Lightning. I hope the challenge creators take this up as feedback. I spent the whole day trying to figure out what went wrong!!! 10 hours wasted!
Rodrigo Soares 13Rodrigo Soares 13
I'm still stuck ...
In the Pricebook speaks that the Id is duplicated, and when I go up Opportunity Contact Role presents colleague's mistake above: "Price Book Entry ID: id value of incorrect type:"
Kevin_FleckKevin_Fleck
I'm stuck too, keep getting "Please check that all of the relationships are maintained for Opportunity Contacts and Adventure Packages that you upload from the spreadsheet." every single time. Nothing works. SF can be the most rewarding and most frustrating platform to use at the same time I swear.
Deepak Tumkur ShivanandaiahDeepak Tumkur Shivanandaiah
@Rodrigo Soares 13 @Kevin_Fleck

Go to your dev console, open Execute Ananymous Window and run the following query,
 
List<Object> aa = [SELECT Id FROM Pricebook2 WHERE Name = 'Standard Price Book'];

After this open your log and look for something like this,
"VARIABLE_ASSIGNMENT [1]|aa|[{"Id":"01sf4000002InuwAAC"}]|0x39d95265".

This will give you the ID of the 'Pricebookid', copy the id part in your console and paste it in the 'Pricebookid' column of the  Adventure.csv file you downloaded above.
You need to change the id in all three of the entries. Same ID for all the rows.

The problem is that the ID in the downloaded .csv is not matching with the ID in your org, just change the ID and it should work.
Make sure you map all that is mentioned and look ups too should be mapped correctly also.
It will work if you do it right. Try and fell free to ask if you still get any probelms.  
Kevin_FleckKevin_Fleck
Thanks for the help, no luck yet, how do you map look ups?
Kevin_FleckKevin_Fleck
YES!! Nevermine I passed it! To all rookie dolts like myself DATALOADER.IO is a website, not something found on app exchange, and is completely different from the DATA LOADER APP WHICH DOES NOT WORK WITH THIS CHALLENGE (for me anyway).
Joao Dias 11Joao Dias 11
Thank you!!
J_DulbJ_Dulb
I have been struggling with this for so long & created multiple new orgs to try again. I followed everything step by step but kept getting the "Please check that all of the relationships are maintained for Opportunity Contacts and Adventure Packages that you upload from the spreadsheet." error. 

One additional fix that is worth a try is checking the log in the Developer Console. I saw it was making the query "SELECT id, name FROM product2 WHERE productcode = 'mtt'" and then the assertion was failing. Upon looking at my list of Adventures in Salesforce, I realized that productcode was never set/mapped. I edited the items to include these codes and I was able to complete the challenge. I hope this helps!

Also, thank you so much for making this original post! It was extremely helpful!
Lisa SouletLisa Soulet
Thank you so much, Ludvig.  You are a lifesaver!
 
Nancy Gupta 33Nancy Gupta 33
Hi @Ludvig Wälimaa @manoj krishna @Lisa Soulet

I am facing this error while inserting the records mentioned in the 7th step -- Insert Adventure Package from OpportunitiesWAdventures.csv 

Could not find PricebookEntry with the Name of 'Susan Johanson - Milford Track - 2026'.

Please help me where I am wrong??
Anup KabraAnup Kabra
I followed the steps as mentioned by Ludvig Wälimaa but I keep on getting below message.

Challenge Not yet complete... here's what's wrong: 
Please check that all of the relationships are maintained for Opportunity Contacts and Adventure Packages that you upload from the spreadsheet.
DlengDleng

Thank you for this step-by-step guide. I am unable to import data to Price Book Entry though, I'm getting this error all the time and I am about to lose my mind.

SOURCE: 'Product2Id' DESTINATION: 'Product2Id' ERROR:Adventure: id value of incorrect type: Machu Picchu Trek 
Where I am doing the mistake? I am following the guide and the hints in the comments (i.e. changed PricebookId to an actual ID from my dev org), but so far zippo.
Rishabh Sharma 53Rishabh Sharma 53
Hi,

I tried with all the steps mentioned but i am still getting error
"Challenge Not yet complete... here's what's wrong: 
Please check that all of the relationships are maintained for Opportunity Contacts and Adventure Packages that you upload from the spreadsheet."

Here is the sequence in which I imported the Data
1. Explorer Insert.
2. Adventure Insert
3. Opportunity Insert
4. Opportunity Contact Role
5. Price Book Entry.
6. Adventure Package.

Am i Facing issue because of the sequence? If yes, how do i delete the previous data, i tried deleting Data from Explorer via Dataloader.io but could not map the ID and was unsuccessful.

Any thoughts why am i getting the error?

Thanks in Advance

 
Rishabh Sharma 53Rishabh Sharma 53
@Dieng,

Did you try changing the Price Book id in your sheet?

Execute below query in your developer console and copy the value
SELECT Id FROM Pricebook2 WHERE Name = 'Standard Price Book'


update the "Pricebookid" record in "your Adventure.csv" file with result you get from above query.

Upload this file with Mapping instructions mentioned by author
Neeta SatishNeeta Satish
@Rishbh Sharma 53, 
Check your mapped fields (lookups) while Inserting Opportunity Contact Role and Adventure Package.
 
Neeta SatishNeeta Satish
@Dleng, this is definitely a mapping issue. I had got the same error too. I resolved it by remapping the fields.
Nancy Gupta 33Nancy Gupta 33
Hi @Neeta Satish,

I am facing this error while inserting the records mentioned in the 7th step -- Insert Adventure Package from OpportunitiesWAdventures.csv 

Could not find PricebookEntry with the Name of 'Susan Johanson - Milford Track - 2026'.

Please help me where m wrong.
Robert Baillie 10Robert Baillie 10
@Nancy
Sounds like you're mapping the Name of the Opportunity to the PriceBookEntry - you should map the Product Code in the file to the PriceBookEntry -> Product code instead.
Naeem T-PearsonNaeem T-Pearson
@Ludvig Wälimaa
ive done everything ther exactly as you said it and still i still get this error
Challenge Not yet complete... here's what's wrong: 
Please check that all of the relationships are maintained for Opportunity Contacts and Adventure Packages that you upload from the spreadsheet.
ive even manually mapped the contact roles and adventure package with the data loader app and still Got the same error
even though through that way I still got the same error
I have no idea what i am doing wrong
J_DulbJ_Dulb
@Naeem T-Perason have you checked to see if the "productcode" field was set/mapped?
Dexter Martin 3Dexter Martin 3
I am working on superbadge: Lightning Experience SpecialistLightning Experience Specialist. I have spent 5 days on challenge 8.which is importating data. I am having trouble with the entire challenge 8 but most specifically the following error when I try and load data into the Adventure Package.SOURCE: 'OpportunityId' DESTINATION: 'OpportunityId' ERROR:Opportunity ID: id value of incorrect type: Susan Johanson - Milford Track - 2026
DM MTNDM MTN
The following is confusing because OriceBookEntry requires PricebookId2 and ProductId2. Additionally, a Standard Price must be set to be accepted into PriceBookEntry:

Insert Price Book Entry from Adventures.csv
The Adventures has to be in the Price Book to be able to be added to an Adventure Package. Therefore I added a column in the called PricebookID and added the Pricebook ID of the Standard Price Book to the rows. 
Mapped field:
Adventure Name - Adventure (Lookup via Adventure Name)
List Price - List Price
Active (Adventure) - Active
Pricebookid - Price Book ID
 
Andrea WallaceAndrea Wallace
Run this query if you are struggling with step 7.  (To make sure you have the right pricebookentry IDs that match to the correct Adventure.)  SELECT name,Id FROM PricebookEntry
Brandon LibmanBrandon Libman
Andrea's comment above helped me.

Turns out that when I ran the query, the values in Step 7 for your new "Adventure Name" column are as follows:

"Milford Track Trek",
"Machu Picchu Trek", and
"Half Dome Hike" respectively.

Good luck,
Brandon
varuna nikam 19varuna nikam 19
@Rishabh Sharma 53

I tried with what you have mentioned but i am getting below error
Could not find Pricebook2 with the Name of '01s7F0000070EB4QAM'.
 
Lokesh Krishna SagiLokesh Krishna Sagi
@varuna nikam 19 add PricebookId column to your adventure.csv sheet and get the PricebookId with this soql in developer console and add that Id in all rows like this. Map that column with Id field. It worked for me.
SELECT Id FROM Pricebook2 WHERE Name = 'Standard Price Book' User-added image
varuna nikam 19varuna nikam 19
@Lokesh Krishna Sagi

Challenge Not yet complete... here's what's wrong: 
Please check that all of the relationships are maintained for Opportunity Contacts and Adventure Packages that you upload from the spreadsheet.

I managed to insert all the data still i am getting this error.
Lokesh Krishna SagiLokesh Krishna Sagi
@varuna nikam 19,,, did you map all the fileds mentioned by author in step 6 and 7 ? In step7, you should map the Product Code column from .csv file to the PriceBookEntry(->Product Code) instead of mapping adventure name to the Price Book Entry Id. Try it.. 
varuna nikam 19varuna nikam 19
@Lokesh Krishna Sagi

While inserting Price Book Entry I am getting error "Could not find Pricebook2 with the Name of '01s7F0000070EB4QAM' this is same id what i got from Standard price book.And when i try to insert adventure package at that time "Could not find PricebookEntry with the ProductCode of 'MTT". I  tried with this " you should map the Product Code column from .csv file to the PriceBookEntry(->Product Code) instead of mapping adventure name to the Price Book Entry Id."
Lokesh Krishna SagiLokesh Krishna Sagi
User-added image
This is my mapping status from dataloader..for step 7.
varuna nikam 19varuna nikam 19
@Lokesh Krishna Sagi

Thanks Lokesh !!!
I deleted all the data and tried again .It worked for me.
Lokesh Krishna SagiLokesh Krishna Sagi
@varuna nikam 19...glad it helped..Enjoy!!!
elaine gilmanelaine gilman
I'd like to nominate you all for sainthood. This thread was invaluable to me. Thanks!
Hanna Kirmula 1Hanna Kirmula 1
A real Challenge and without Ludvig's instructions couldn't solve ever I think. I assume that if you are reading this you are most probably having some issues. The mistake I made was that I didn't use dataloader.io but only dataloader. So, dataloader.io is "a must" here.
Harsha GadagHarsha Gadag
@Dexter Martin 3

Just check if you have mapped the fields correctly.
Venu M 18Venu M 18
@Ludvig Wälimaa,
Wow.. Without this forum page I don't think I could have done this.
Thank You. Just finished 8th module.
Only thing I additionally added is: In the 7th point it asked me for Quantity & Total Price.
Dima BondarenkoDima Bondarenko
God Bless you and all your family!!!
Arpit AgarwalArpit Agarwal
@Ludvig : Thanks a lot for the solution. Without such a detailed explanation, I don't think it is possible to pass this step. :)
Brian DarbyBrian Darby
@Ludvig Wälimaa,
You are the man.
NAVEEN KUMARNAVEEN KUMAR
@Ludvig Wälimaa , Thank you so much.. it works..
Luis VarelaLuis Varela

Dear @Ludvig Wälimaa,

cant thank you enough for this detailed guide!

Cheers
Luis
Stephen Clissold 6Stephen Clissold 6
@Ludvig

Thanks for the tips and tricks there really helped out!.
Lorenzo CalòLorenzo Calò
I can't Map the Adventure.csv field with Pricebook Entry field!
See the image below!
User-added image

Can you help me please? it's the last step to take this Challenge