cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Anonymous
Not applicable

Model Driven Apps - Migrating Lookup Fields into Custom Entity

I am trying to upload 1000s of records into a custom entity on model driven Power Apps. I am able to read in text fields, option sets, dates, etc without any issue. However when I try to map lookup fields, I get an error that says "can't resolve the guid for the lookup field:...". I am able to select "Edit in Excel" in an entity where I can manually select the appropriate lookup choice. But i can not copy and paste the item name because it does not recognize it as a GUID. There is too much data to do this and I need a way to complete this in a programmatic way.

 

I essentially want to relate the Product IDs  (500004, 500370, etc) to the POBs (POB-1000, POB-1001, etc), as records that I can connect together after migrating the information to the model driven app.

Product ID Mapping.PNG

 

Error_Import.PNG

Thank you

1 ACCEPTED SOLUTION

Accepted Solutions
Super User
Super User

Re: Model Driven Apps - Migrating Lookup Fields into Custom Entity

Hi @Anonymous 

By far the best way to import relational data is using the dynamics 365 data import wizard.  Go to https://admin.powerplatform.microsoft.com/support and select environments then select the environment for your data.  In the top panel there is a gear marked settings.  Click on this and on the right side of the screen is an option called data import wizard.  There are nuances to using it so I suggest reading about it in the blog importing-data-in-microsoft-dynamics-crm/the-data-import-wizard-in-dynamics-crm/  first.  I have found that it works best if you create the entities first and assign the fields so that they match exactly the fields to be imported. Also check out https://survivingcrm.com/2011/11/crm-2011-data-import-wizard-in-practice/  in the section for mapping related records based on custom ID fields. This is not a comprehensive answer but it should get you started.  If you have already got the entities created then you can also use the template option for your preexisting data.Capture.PNG

View solution in original post

8 REPLIES 8
Super User
Super User

Re: Model Driven Apps - Migrating Lookup Fields into Custom Entity

Hi @Anonymous 

By far the best way to import relational data is using the dynamics 365 data import wizard.  Go to https://admin.powerplatform.microsoft.com/support and select environments then select the environment for your data.  In the top panel there is a gear marked settings.  Click on this and on the right side of the screen is an option called data import wizard.  There are nuances to using it so I suggest reading about it in the blog importing-data-in-microsoft-dynamics-crm/the-data-import-wizard-in-dynamics-crm/  first.  I have found that it works best if you create the entities first and assign the fields so that they match exactly the fields to be imported. Also check out https://survivingcrm.com/2011/11/crm-2011-data-import-wizard-in-practice/  in the section for mapping related records based on custom ID fields. This is not a comprehensive answer but it should get you started.  If you have already got the entities created then you can also use the template option for your preexisting data.Capture.PNG

View solution in original post

Anonymous
Not applicable

Re: Model Driven Apps - Migrating Lookup Fields into Custom Entity

Thank you!! This has been much smoother then what I was trying from the start.

Super User
Super User

Re: Model Driven Apps - Migrating Lookup Fields into Custom Entity

HI @Anonymous 

Happy to help.  I have spent weeks on importing relational data until I found this wizard.

Anonymous
Not applicable

Re: Model Driven Apps - Migrating Lookup Fields into Custom Entity

So I have gotten the data import to work, and it properly connects all of the right records together. But for some reason, after about 5 minutes, all of my records on one side get deleted and the connections are lost. Have you ever had this problem?

Super User
Super User

Re: Model Driven Apps - Migrating Lookup Fields into Custom Entity

Hi @Anonymous 

Wow, I haven't seen this behavior.  If you download the excel file from the entity is the data really gone?  

Anonymous
Not applicable

Re: Model Driven Apps - Migrating Lookup Fields into Custom Entity

Yes, i import the data, it all looks great. Then I import another set of data and map it to the data I imported first. This allows me to create that lookup relationship to go between records. Then about 20 minutes later, 90% of the data disappears. The rest of the data leaves shortly after. 

 

Maybe there is something i deleted early on that was related to the record and once the system realizes they exist, it deletes them? I have no clue.

Anonymous
Not applicable

Re: Model Driven Apps - Migrating Lookup Fields into Custom Entity

The record that deletes itself has a primary field that is an auto number and I am reading in my own Titles. Not sure if that could be the problem.

Anonymous
Not applicable

Re: Model Driven Apps - Migrating Lookup Fields into Custom Entity

I must have deleted some parent entity or something related to the entity i was working with. I just migrated everything to a new entity and it all worked fine. Thanks again.

Helpful resources

Announcements
MBAS Gallery 2020

MBAS Gallery 2020

Watch Microsoft Business Applications Summit sessions on-demand.

firstImage

New Ranks and Rank Icons released on April 21!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power Apps Community!

Power Platform 2020 release wave 1 plan

Power Platform 2020 release wave 1 plan

Features releasing from April 2020 through September 2020

Top Solution Authors
Top Kudoed Authors
Users online (8,252)