Skip to main content

Notifications

Microsoft Dynamics CRM (Archived)

Creating this parental association would create a loop in this entity hierarchy

Posted on by 1,075

Hello,

I have a need of adding a Contact lookup field on Contact entity as Updated By. I need to capture Contact record updated by if it updates it's own email or phone. It works fine if contact is updated by on other contact. But it fails with an error "Creating this parental association would create a loop in this entity hierarchy", when it updates its own information (email and phone). I know it is OOB restriction added for hierarchy view feature. It is something like self-referencing. Any thoughts how to get rid of this restriction? 

*This post is locked for comments

  • Suggested answer
    pavanmanideep Profile Picture
    pavanmanideep 1,329 on at
  • RE: Creating this parental association would create a loop in this entity hierarchy

    Kokulan - Your workaround sounds like quite possible. But not ideal. Anyway, thanks for the idea.

  • RE: Creating this parental association would create a loop in this entity hierarchy

    Pavan - Even it is not possible with Referential relationship behavior. I know it is not possible self-reference will all types of relationship behavior.

  • Suggested answer
    Kokulan Profile Picture
    Kokulan 18,048 on at
    RE: Creating this parental association would create a loop in this entity hierarchy

    Hi

    You will not be able to set the Updated by to be the same contact.

    One workaround to this limitation would be to create a common or fixed contact record, you could call it: Same Person / Self or something along the line

    Whenever you have a scenario of the same contact performing the update, just set the Updated By to be Same Person / Self

  • Suggested answer
    pavanmanideep Profile Picture
    pavanmanideep 1,329 on at
    RE: Creating this parental association would create a loop in this entity hierarchy

    Hi Vijay,

    If the entity relationship behavior is defined as Parental it is not possible for a record to reference itself because this would create a circular reference.

    docs.microsoft.com/.../customize-entity-relationship-metadata

    Instead you can easily use the OOB Modified By field for Updated By in the Contact for your requirement...

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,253 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,188 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans