cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
kv
Helper II
Helper II

Error while importing managed solution to production (Failed to upgrade solution. Solution dependencies exist, cannot uninstall)

We have a sandbox environment and a production environment. We develop on sandbox and deploy to production as managed (with version bump and upgrade). In the last deploy, a table was missing in the solution, because it was removed from the solution. The table still exists in our sandbox environment.

 

Now, we deployed the solution to production, which led to an error: Failed to upgrade solution. Solution dependencies exist, cannot uninstall. The error is caused because a table was missing in the solution and Dynamics tried to delete the table during the upgrade. There are now two versions of our solution on production:

 

kv_0-1669986872688.png

 

My question is: is it safe to delete the "_Upgrade" solution in production, and then to import the solution again from sandbox, but this time with the missing table?

2 ACCEPTED SOLUTIONS

Accepted Solutions
kv
Helper II
Helper II

Just found this piece of advice from Microsoft (Removing dependencies (Microsoft Dataverse) - Power Platform | Microsoft Learn). Seems safe to delete the _Upgrade solution:

 

If you're trying to upgrade a solution

In this case, you must confirm that you wanted to delete the required component (remember that dependencies are enforced only on components that are being deleted).

If you didn't want to delete the component, you can fix the new version of the solution by adding the component back by doing the following:

  1. In the target organization, uninstall the staged solution (the solution that ends in _Upgrade).
  2. In the source organization, add the required component(s) back to the solution.
  3. Export the new version.
  4. Retry the upgrade.

If the deletion is intentional, you must remove the dependency. Try the steps outlined in the preceding section, "If you're trying to uninstall a solution."

View solution in original post

AJ_Z
Super User
Super User

You are correct and it is safe to remove the upgraded one 🙂



Signature:


If you appreciated my comments/responses please be sure to Like/Kudo them it really does make me smile 🙂 !
Link to the Power Platform Professionals United Kingdom User Group:

https://powerusers.microsoft.com/t5/Power-Platform-Professionals/gh-p/PowerPlatformProfessionalsUnit...

View solution in original post

5 REPLIES 5
kv
Helper II
Helper II

Just found this piece of advice from Microsoft (Removing dependencies (Microsoft Dataverse) - Power Platform | Microsoft Learn). Seems safe to delete the _Upgrade solution:

 

If you're trying to upgrade a solution

In this case, you must confirm that you wanted to delete the required component (remember that dependencies are enforced only on components that are being deleted).

If you didn't want to delete the component, you can fix the new version of the solution by adding the component back by doing the following:

  1. In the target organization, uninstall the staged solution (the solution that ends in _Upgrade).
  2. In the source organization, add the required component(s) back to the solution.
  3. Export the new version.
  4. Retry the upgrade.

If the deletion is intentional, you must remove the dependency. Try the steps outlined in the preceding section, "If you're trying to uninstall a solution."

AJ_Z
Super User
Super User

You are correct and it is safe to remove the upgraded one 🙂



Signature:


If you appreciated my comments/responses please be sure to Like/Kudo them it really does make me smile 🙂 !
Link to the Power Platform Professionals United Kingdom User Group:

https://powerusers.microsoft.com/t5/Power-Platform-Professionals/gh-p/PowerPlatformProfessionalsUnit...

kv
Helper II
Helper II

Thank you, trying it out now. I'll keep the thread updated.

kv
Helper II
Helper II

It worked. We deleted the *_Upgrade solution. Then we exported the solution from the sandbox environment with the previously missing table, and imported it successfully to production.

AJ_Z
Super User
Super User

Perfect I am happy to hear that it worked for you 🙂



Signature:


If you appreciated my comments/responses please be sure to Like/Kudo them it really does make me smile 🙂 !
Link to the Power Platform Professionals United Kingdom User Group:

https://powerusers.microsoft.com/t5/Power-Platform-Professionals/gh-p/PowerPlatformProfessionalsUnit...

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Users online (5,650)