Within my series about Microsoft Graph in the Power Platform I’ve collected data using customer connectors and HTTP actions but how do we filter and select data in Microsoft Graph?
Filter Action To filter our data that we get returned we could use the filter action. But that would mean collecting too much data before
Filter Action
Filtering data in Power Automate
Microsoft Graph and filtering
The two approaches to filtering and selecting data from Microsoft Graph in Power Automate are using OData filters or the Get Items action with a filter query.
When using OData filters, you can use an expression such as “startswith(name,'Smith') eq true” which will return any results where the name begins with Smith. You can also add additional parameters to refine your search further, such as '$filter=contains(name, 'John')'. This makes it easier to find specific items that match certain criteria quickly and efficiently.
The other approach is to use the Get Items action with a Filter Query parameter. This allows you to specify conditions for what records should be returned by querying based on values of one or more properties in the result set. For example, if you wanted to get all users whose displayName starts with "Smith", then your filter query would look like this: "$filter=startsWith(displayName,'Smith')". With this approach, it's possible to build complex queries that involve multiple properties and conditions which can help narrow down your results even further.
Jan 4, 2023 — Use the $filter query parameter to retrieve just a subset of a collection. For guidance on using $filter , see Use the $filter query parameter ...
6 days ago — Learn how to use the $filter OData query parameter and its operators against different types of properties in Microsoft Graph.
May 19, 2020 — Build advanced queries in Microsoft Graph with $count, $filter, $search, and $orderby · Select the beta endpoint · Add $count=true in the ...