Query all Entities in a Dataverse Solutions


ERD of Solution Component Query Examples

This blog post demonstrates how to query any component type in a solution.

The two examples used are to query all entities in a solution and all security roles in a solution.


The sample D365 Freelancing solution has three entities, contacts, accounts and custom entities. Contact and account are out-of-the-box entities and the custom entity is, surprisingly :), a custom entity. The D365 Freelancing solution also has the out of the box Sales Manager role in it.

Sample D365 Freelancing Solution

The fetch XML queries the Solution Component entity. Linking to the Solution entity so we can filter by the solution name and also linking to the Entity entity so we can get metadata details regarding each entity in the solution. Any component in a solution can be found this way and is demonstrated with a second Fetch XML query displaying all Security Roles in a solution. Simply create a linked entity to the component to query and link on the Solution Component objected and the actual component's primary id (entityid and roleid in these examples).


Entities in a Solution Fetch XML Example

Entities in a Solution Query Results

Security Roles in a Solution Fetch XML Example

Security Roles in a Solution Query Results

15 views0 comments

Recent Posts

See All

There are a number of tricks that can help improve the speed of data migrations. I have bullet pointed them below and included links and references at the bottom of the page. Turn off all workflows (i

Power Platform storage seems to get consumed very quickly. I have had to come up with capacity management strategies for numerous clients over the years. I really do wish Microsoft would increase the