Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics 365 | Integration, Dataverse...
Suggested answer

Solution import fails due to missing relationship

Posted on by 249

Managed solution exported from sandbox, trying to import in to live. It says there is a missing entity relationship, but the relationship has been included in the solution. The parent_contactid is a field that I think got created when using the Org Chart functionality on the account form.

pastedimage1577193355576v1.png

pastedimage1577193427190v2.png

  • slx Profile Picture
    slx 386 on at
    RE: Solution import fails due to missing relationship

    Can you use parent_contactid to define a parental relationship for contact with itself ?

    Example one contact is a parent of other contact, can this be stored in the parent_contactid or better use other field ?

  • ErikLm Profile Picture
    ErikLm 55 on at
    RE: Solution import fails due to missing relationship

    Hi,

    I've encountered the exact same problem as you, did you manage to solve the problem?

  • Suggested answer
    Asif365 Profile Picture
    Asif365 1,431 on at
    RE: Solution import fails due to missing relationship

    Before export a solution , a following steps to be checked

    - All the required components to be exported

    - All the plug in , process and work flow must be deactivate and then export the solution and import the solution surely it will work.

    You can also try other methods and have a look at this links:

    msft-crm.blogspot.com/.../solution-import-failed-entity.html

    support.microsoft.com/.../import-of-solution-fails-due-to-missing-components

  • Suggested answer
    Paul_Owen Profile Picture
    Paul_Owen 2,027 on at
    RE: Solution import fails due to missing relationship

    Are those relationships in the Navigation panel on the form? If so remove them and try your import again.

    Regards

    Paul

  • Suggested answer
    ashish12 Profile Picture
    ashish12 3,079 on at
    RE: Solution import fails due to missing relationship

    Create another solution and add only entities and components are required, then try to import the solution.

  • pawin Profile Picture
    pawin 249 on at
    RE: Solution import fails due to missing relationship

    I have enabled the org chart functionality in the destination environment, so the field and the relationship exists there.

    I have also included the parent_contactid field in the managed solution, as well as the relationship.

    There error is still occurring.

    Removing a missing dependency section from the solution.xml file will mean I have to do that every time I export/import won't it? Presumably this is a bug? No other relationships are causing the same issue.

  • Suggested answer
    ba365guy Profile Picture
    ba365guy 2,946 on at
    RE: Solution import fails due to missing relationship

    If you desired to use Org. Chart functionality, please enable the same in the target environment too. Missing dependency might be sorted out.

  • RE: Solution import fails due to missing relationship

    Hi Partner,

    The issue here is the contact field "parent_contactid" that is added in the unmanaged layer on contact.

     

    This field is created when customers use the Open Org Chart feature. The feature will create a relationship from contact to itself so that you can represent a customer org chart.  It is doing this in the unmanaged layer since it is not already in your schema. 

     

    "parent_contactid" is used for hierarchy enablement for OrgChart functionality. When OrgChart is used for the first time, if there is no hierarchy relationship on contact entity, it is auto created. More details can be found here:

     

    Here is the documentation page on that – note the important blue box that is on the top of the page.  https://docs.microsoft.com/en-us/dynamics365/customer-engagement/sales-enterprise/live-org-chart

     

    I believe the issue is that someone configured your source environment using the org chart functionality, which added the unmanaged property.  If this property is desired, you should be able to simply add the field to your solution and ship it to the other environment.  If it is not desired to be shipped, then the best practice is to remove it from your source environment.

    So you can import the solution by manual removing the <missing dependency> tag in the solution.xml file

     2476.image.png

    Hope this helps.

    Best regards,

    Akash

    Please mark as verified if the answer is helpful. Welcome to join hot discussions in Dynamics 365 Forums.

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!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,235 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans