Create N:N (many-to-many) table relationships in Microsoft Dataverse using solution explorer
Effective November 2020:
- Common Data Service has been renamed to Microsoft Dataverse. Learn more
- Some terminology in Microsoft Dataverse has been updated. For example, entity is now table and field is now column. Learn more
This article will be updated soon to reflect the latest terminology.
Solution explorer provides one way to create and edit N:N (many-to-many) for Dataverse.
The Power Apps portal enables configuring the most common options, but certain options can only be set using solution explorer. More information:
- Create Many-to-many (N:N) table relationships
- Create Many-to-many table relationships in Dataverse using Power Apps portal
Open solution explorer
Part of the name of any custom relationship you create is the customization prefix. This is set based on the solution publisher for the solution you’re working in. If you care about the customization prefix, make sure that you are working in an unmanaged solution where the customization prefix is the one you want for this table. More information: Change the solution publisher prefix
Navigate to an unmanaged solution
From the Power Apps portal select Solutions, and then on the toolbar, select Switch to classic.
In the All Solutions list select the unmanaged solution you want.
View table relationships
In solution explorer, expand Tables an select a table. Within that table, select N:N Relationships.
While viewing table relationships, select New Many-to-Many Relationship from the command bar.
If the command is not available, the table is not eligible to create a custom relationship.
In the Other table group, in the table Name column, choose the table that you want to create the relationship with. This will populate the Name and Relationship table Name columns in the Relationship Definition group.
You can click to save the table and continue editing. More information: Edit relationships
If either the Name or Relationship table Name values already exist in the system you will get an error when you save. Edit the values so that they are unique and try again.
While viewing table relationships, select the table you want to edit.
The publisher of a managed solution can prevent customizations of relationships that are part of their solution.
The following table relationship properties can be edited after the relationship is created.
After you edit these properties you must publish customizations before they will take effect in model-driven apps.
Edit Display options
For both the Current table and the Other table, you can edit the display option columns which control how the related tables are displayed for model-driven apps.
|Display Option||How the related table list should be displayed. More information: Display Options|
|Custom Label||Specify the localizable text to be used instead of the plural name when you select Use Custom Label as the Display Option .|
|Display Area||Select one of the available groupings to display this list. The available options are: Details (for the Common group), Marketing, Sales, and Service.|
|Display Order||Controls where the navigation item will be included within the selected display area. The range of allowed numbers begins with 10,000. Navigation pane items with a lower value appear above other relationships with a higher value.|
These are the available display options:
|Do not Display||Do not display the related tables for this relationship.|
|Use Custom Label||When this option is chosen, the Custom Label column is enabled so that you can specify the localizable text to be used instead of the plural name.|
|Use Plural Name||Use the plural display name defined for the related table.|
You can hide the relationship from Advanced Find in model-driven apps by setting the Searchable column to No.
While viewing table relationships, select the table relationship you want to delete and click the command.
Deleting the relationship will delete the relationship table created. All data connecting tables using the relationship will be lost.