Create many-to-many entity relationships overview
One-to-many (1:N) entity relationships establish a hierarchy between records. With Many-to-many (N:N) relationships there is no explicit hierarchy. There are no lookup fields or behaviors to configure. Records created using Many-to-many relationships can be considered peers and the relationship is reciprocal.
With Many-to-many relationships a Relationship (or Intersect) entity stores the data that associates the entities. This entity has a One-to-many entity relationship with both of the related entities and only stores the necessary values to define the relationship. You can’t add custom fields to a relationship entity and it is never visible in the user interface.
Creating a Many-to-many relationship requires choosing the two entities that you want to participate in the relationship. For model-driven apps you can decide how you want the respective lists to be available within the navigation for each entity. These are the same options used for the primary entity in 1:N entity relationships. More information: Navigation Pane Item for Primary Entity
Not all entities can be used with Many-to-many relationships. If the entity isn't available to be chosen in the designer, you can’t create a new Many-to-many relationship with this entity. More information: Developer documentation: Entity relationship eligibility
There are two designers you can use to create and edit 1:N (one-to-many) or N:1 (many-to-one) relationships:
Designer | Description |
---|---|
Power Apps portal | Provides an easy streamlined experience, but some special settings are not available. More information: Create Many-to-many entity relationships in Common Data Service using Power Apps portal |
Solution explorer | Not as easy, but provides for more flexibility for less common requirements. More information: Create N:N (many-to-many) entity relationships in Common Data Service using solution explorer |
Note
You can also create new Many-to-many (N:N) entity relationship in your environment using the following:
- Import a solution that contains the definition of the relationship. More information: Import, update, and export solutions
- A developer can use Metadata services to write a program to create and update entity relationships. More information: Developer documentation: Customize entity relationship metadata
Information in this topic will help you choose which designer you can use.
You should use the Power Apps portal to create and edit Many-to-many (N:N) entity relationships unless you need to address any of the following requirements:
- Configure navigation pane options for model-driven apps.
- Hide the relationship from Advanced find in model-driven apps.
See also
Create and edit relationships between entities
Create Many-to-many entity relationships in Common Data Service using Power Apps portal
Create N:N (many-to-many) entity relationships in Common Data Service using solution explorer
Developer documentation: Customize entity relationship metadata
Developer documentation: Entity relationship eligibility
Feedback
Loading feedback...