Skip to main content

Notifications

Announcements

No record found.

Customer experience | Sales, Customer Insights,...
Suggested answer

Unable to delete unused entities

Posted on by

Objectives: We are trying to delete some unused entities

Server Info: We are currently running Windows Server 2019, with SQL Server 2017 CU20, Dynamics CRM 9.0.15.9

Problem: When we are trying to delete, we are being asked to clear dependencies. However, some dependencies we were not able to fix as system is not allowing us

We are getting 2 kind of issues

1st Issue: When we are trying to delete, we are getting SQL exception as mentioned below, Also, find the Log file attached
pastedimage1593080831945v1.png[View:/cfs-file/__key/communityserver-discussions-components-files/117/MS_2D00_SQL_2D00_Issue_2D00_While_2D00_Delete.txt]

Action taken so far: We tried to enable verbose tracing in ms crm server, but it is showing same error.

2nd Issue: When We are trying to delete one 1:M relationship and during delete we were provided multiple dependencies which we were was able to clean perfectly. However, for one dependency, on clicking on it, nothing is happening

pastedimage1593080998840v2.png

Action Taken so far and understanding: in the db (p_RetrieveDependenciesForDelete), we found that it is referring one dependency. We have seen in the formXML using customization XML, but not able to find any problem or find anything. But, due to this restriction we are not . we tried to delete the dependencies from db end, however, it seems too risky, so seeking help.

  • Kamalesh82 Profile Picture
    Kamalesh82 50 on at
    RE: Unable to delete unused entities

    Just an update. using metadataservice as well, same exception was thrown.

  • Suggested answer
    Bipin D365 Profile Picture
    Bipin D365 28,964 Super User 2024 Season 1 on at
    RE: Unable to delete unused entities

    Hi,

    As Generic SQL Error does not help us to identity the issue. That is why I asked to check it from C# to see if detailed error is being display to investigate this issue.

    Please Mark My Answer Verified If I Were Helpful

  • Kamalesh82 Profile Picture
    Kamalesh82 50 on at
    RE: Unable to delete unused entities

    Thanks for reply. Though We have not tried this, but as this issue is coming from server level, I am not sure using Metadata Service will able to help us. Did you have faced such issue before, please suggest if we suggest.

  • Suggested answer
    Bipin D365 Profile Picture
    Bipin D365 28,964 Super User 2024 Season 1 on at
    RE: Unable to delete unused entities

    Hi,

    First Issue -

    Can you try deleting entity from C# code and see what is happening.

    Second issue -

    Check if relationship is removed from Form navigation on form editor.

    If found helpful, Please mark my answer verified.

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,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