Skip to content

Fix v4.31 upgrade failure: Add missing Abandoned PowerApps SavedQuery to Core Components#10826

Closed
Copilot wants to merge 5 commits intomainfrom
copilot/fix-import-error-center-of-excellence
Closed

Fix v4.31 upgrade failure: Add missing Abandoned PowerApps SavedQuery to Core Components#10826
Copilot wants to merge 5 commits intomainfrom
copilot/fix-import-error-center-of-excellence

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Feb 9, 2026

Problem

Upgrades from v4.31 to any later version fail with SavedQuery(f9d327af-b6b4-e911-a85b-000d3a372932) cannot be deleted because it is referenced by 1 other component. The "Abandoned PowerApps" view exists only in CoreComponentsTeams, but Power Platform Admin View app references it during Core Components upgrade, creating an unresolvable dependency.

Changes

Core Fix

  • Added CenterofExcellenceCoreComponents/SolutionPackage/src/Entities/admin_App/SavedQueries/{f9d327af-b6b4-e911-a85b-000d3a372932}.xml
    • Filters apps where cr5d5_appisorphaned = yes (owner account no longer exists)
    • Matches existing "Abandoned Flows" view pattern
    • Dependent field already exists in Core Components

Documentation

  • Updated TROUBLESHOOTING-UPGRADES.md with v4.31 resolution steps
  • Added docs/ISSUE-ANALYSIS-UPGRADE-V431-SAVEDQUERY.md with root cause analysis
  • Added SOLUTION-SUMMARY-V431-UPGRADE-FIX.md with testing plan

Technical Details

SavedQuery structure:

<savedquery>
  <savedqueryid>{f9d327af-b6b4-e911-a85b-000d3a372932}</savedqueryid>
  <fetchxml>
    <entity name="admin_app">
      <attribute name="admin_displayname" />
      <filter type="and">
        <condition attribute="cr5d5_appisorphaned" operator="eq" value="yes" />
      </filter>
    </entity>
  </fetchxml>
  <LocalizedNames>
    <LocalizedName description="Abandoned PowerApps" languagecode="1033" />
  </LocalizedNames>
</savedquery>

Including the view in Core Components eliminates the dependency conflict during solution upgrade while providing legitimate governance capability for identifying orphaned apps.

Original prompt

This section details on the original issue you should resolve

<issue_title>[CoE Starter Kit - BUG] Solution "Center of Excellence - Core Components" failed to import: ImportAsHolding failed with exception :The SavedQuery</issue_title>
<issue_description>### Does this bug already exist in our backlog?

  • I have checked and confirm this is a new bug.

Describe the issue

Trying to update the COE Toolkit from June 2024 v4.31 to Jan 2026 v4.50.8, I'm getting this error: Solution "Center of Excellence - Core Components" failed to import: ImportAsHolding failed with exception :The SavedQuery(f9d327af-b6b4-e911-a85b-000d3a372932) component cannot be deleted because it is referenced by 1 other component.

I already tried to update to older version to see if this was fixed with no luck, also found that the July 2024 version didn't have a package for core components, so I tried the next one, which was August 2024, with exactly the same error.

This SavedQuery(view) is the Abandoned PowerApps view which is used by the Power PLatform Admin View MDA:

Image Image

Expected Behavior

To be able to update the core components solutions to the January 2026 version 4.50.8

What solution are you experiencing the issue with?

Core

What solution version are you using?

4.31

What app or flow are you having the issue with?

Power Platform Admin View

What method are you using to get inventory and telemetry?

Cloud flows

Steps To Reproduce

  1. Download the latest package for the COE Tool Kit.
  2. Unzip
  3. Import the core components solution

Anything else?

I tried to update to the version of the Toolkit as follows

  1. Jan 2026
  2. As pointed out in this other bug [CoE Starter Kit - BUG] Solution "Center of Excellence - Core Components" failed to import: ImportAsHolding failed with exception :The SavedQuery #10158, where you mentioned that the issue was solved in the Sept 2025 version, but it is throwing the same error
  3. Jun 2025
  4. Feb 2025
  5. August 2024

All of them are getting the same error.</issue_description>

<agent_instructions>Upgrade from CoE Core v4.31 to later versions fails with: SavedQuery (f9d327af-b6b4-e911-a85b-000d3a372932) cannot be deleted because it is referenced by another component.
The blocked item is the Abandoned PowerApps view, referenced by the Power Platform Admin View app. All intermediate versions (2024–2026) fail with the same dependency.
Please confirm if this is a packaging issue and provide a workaround to allow upgrading from v4.31.</agent_instructions>

Comments on the Issue (you are @copilot in this section)


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI added 4 commits February 9, 2026 10:45
Resolves upgrade failure from v4.31 where SavedQuery {f9d327af-b6b4-e911-a85b-000d3a372932} cannot be deleted due to dependency reference.

## Problem
- Users upgrading from v4.31 to later versions encounter import error:
  'The SavedQuery(f9d327af-b6b4-e911-a85b-000d3a372932) component cannot be deleted because it is referenced by 1 other component'
- The 'Abandoned PowerApps' view exists in Core Components Teams but not in Core Components
- The cr5d5_appisorphaned field exists in Core Components admin_App entity
- During upgrade, residual dependencies cause conflicts

## Solution
- Add the 'Abandoned PowerApps' SavedQuery to Core Components where it's functionally needed
- Eliminates dependency conflict during upgrades
- Aligns view with its dependent field location
- Maintains functionality for identifying abandoned apps

## Changes
- Added: CenterofExcellenceCoreComponents/.../SavedQueries/{f9d327af-b6b4-e911-a85b-000d3a372932}.xml
- Added: Comprehensive issue analysis documentation

## Testing
- Verify upgrades from v4.31 to current version succeed
- Test fresh installations include the view
- Confirm view functionality with cr5d5_appisorphaned field

Fixes #[issue-number]
Add comprehensive documentation for v4.31 upgrade issue with SavedQuery dependency error. Includes:
- Quick resolution steps for affected users
- Link to detailed technical analysis
- Verification steps after upgrade
- Added to table of contents for easy discovery
Comprehensive summary document including:
- Implementation details
- Testing recommendations
- Communication templates
- Approval checklist
- Technical specifications
Copilot AI changed the title [WIP] Fix import error for Center of Excellence solution Fix v4.31 upgrade failure: Add missing Abandoned PowerApps SavedQuery to Core Components Feb 9, 2026
Copilot AI requested a review from AmarSaiRam February 9, 2026 10:50
@AmarSaiRam AmarSaiRam closed this Mar 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[CoE Starter Kit - BUG] Solution "Center of Excellence - Core Components" failed to import: ImportAsHolding failed with exception :The SavedQuery

2 participants