cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Madumi
Level: Powered On

Import from excel - how do I import/maintain N:N (many to many) relationships?

Hi,

 

I'm new to Powerapps & the Common Data Service--hence the noob question... I'm hoping someone can direct me. I am doing a table import (from Excel spreadsheets) into the database, so I began by exporting to *.csv the blank tables out of CDS. I'll use them as templates to fill in with data & do the import... and I *think* I can figure out how to import/maintain tables related by 1:N relationships (lookup fields from other tables).

 

However, that said, I have two tables (entities), with one field in each joined by a many-to-many relationship. Given that these fields were not exported from my blank CDS database & I can't see a way to populate the intermediary join table inherent in the many-to-many relationship, how can I import the fields related with a many-to-many-relationship?

 

Any hints would be hugely appreciated. I haven't played around with N:N relationships before, so I may have this all backwards (apologies in advance), thx!

2 REPLIES 2
Madumi
Level: Powered On

Re: Import from excel - how do I import/maintain N:N (many to many) relationships?

Hmmm, After reading around, I decided to go a different route & create my own custom intermediary join table/entity to hold all the records for the N:N many to many relationship. That way I can maintain control over the data import process (I have near 30,000 records to import, so manually entering those relationships definitely isn't a good option).

 

I thought I knew how to import entity data that contained lookup fields. As it turns out, I am still feeling my way forward. I found this link, the answer to which (3rd post down) uses the old Dynamics 365 interface, but I'm wondering if there's a better way... When I tried doing it in the Powerapps interface, I set Alternate Keys in the entities referenced by the lookup fields to help map the records, but the import dialogue keeps throwing a "Couldn't resolve the guid for the lookup field: xxxxx_xxxxx" error.

 

Should I just use Dynamics 365 for importing entities with lookup fields, or is there a way to do it in Powerapps?

v-siky-msft
Level 10

Re: Import from excel - how do I import/maintain N:N (many to many) relationships?

Hi @Madumi ,

 

You need some external tools to help you manage NN relationship. I recommend you to use XrmToolBox plugin for Importing N:N relationships.

XrmToolBox https://www.xrmtoolbox.com/ 

Manage NN relationships: https://github.com/MscrmTools/XrmToolBox/wiki/Manage-NN-relationships 

Best regards,

Sik

Helpful resources

Announcements
thirdimage

Power Apps Community User Group Member Badge

Fill out a quick form to claim your user group badge now!

sixthImage

Power Platform World Tour

Find out where you can attend!

Power Platform 2019 release wave 2 plan

Power Platform 2019 release wave 2 plan

Features releasing from October 2019 through March 2020

SecondImage

Difinity Conference

The largest Power BI, Power Platform, and Data conference in New Zealand

Top Kudoed Authors (Last 30 Days)
Users online (5,707)