Skip to main content

Notifications

Community site session details

Community site session details

Session Id :
Customer experience | Sales, Customer Insights,...
Suggested answer

Mapping (1:N Relationships). How to create mapping

(0) ShareShare
ReportReport
Posted on by 20

I'm trying to edit the field mappings in a 1:N relationship. Essentially the relationship is created through an API request for a lookup field and has a single field mapped. What I'm trying to do is query the list of mapped fields and then update that with other fields if needed. 

I looked at the AutoMapEntity Action and know how to edit field mappings in a relationship through the UI, but stuck doing it programmatically. Any help would be appreciated!

  • pentadrian Profile Picture
    20 on at
    RE: Mapping (1:N Relationships). How to create mapping

    Thank you for the link. I had already explored that and found that the mappings are in entity maps and attribute_maps but the relationship mappings are quite a mess there, with no easy way of querying the metadata short of writing multiple connected queries.

    There seems to be the api endpoint for creating a new 1:N relationship (CreateOneToManyRelationship) but that has only a single LookupMetadata field

  • Suggested answer
    Satish Tiwari - CRM Profile Picture
    on at
    RE: Mapping (1:N Relationships). How to create mapping

    Hello,

    You can explore this article - https://docs.microsoft.com/en-us/dynamics365/customerengagement/on-premises/developer/customize-entity-relationship-metadata and see if it helps.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Announcing the Engage with the Community forum!

This forum is your space to connect, share, and grow!

🌸 Community Spring Festival 2025 Challenge Winners! 🌸

Congratulations to all our community participants!

Adis Hodzic – Community Spotlight

We are honored to recognize Adis Hodzic as our May 2025 Community…

Leaderboard > Customer experience | Sales, Customer Insights, CRM

#1
Daivat Vartak (v-9davar) Profile Picture

Daivat Vartak (v-9d... 225 Super User 2025 Season 1

#2
Muhammad Shahzad Shafique Profile Picture

Muhammad Shahzad Sh... 106 Most Valuable Professional

#3
Eugen Podkorytov Profile Picture

Eugen Podkorytov 102

Overall leaderboard

Product updates

Dynamics 365 release plans