Personalized Community is here!
Quickly customize your community to find the content you seek.
Microsoft Customer Co-creation
Help impact how the tools and services you rely on are developed. Microsoft Customer Co-creation connects you directly with our engineers so you can provide feedback before a single line of code is written. Interested? Learn more at Microsoft Customer Co-creation
2022 Release Wave 1 PlanDynamics 365 release plan for the 2022 release wave 1 describes all new features releasing from April 2022 through September 2022.
2022 release wave 1 plan
The FastTrack program is designed to help you accelerate your Dynamics 365 deployment with confidence.
FastTrack Community | FastTrack Program | Finance and Operations TechTalks | Customer Engagement TechTalks | Upcoming TechTalks | All TechTalks
In this post, we’ll see how we can perform aggregate function on data such as Sum or Count using PowerAutomate. Unlike LINQ in C# or SQL, it’s not very straight forward to do using PowerAutomate for which I thought of sharing the approach we had taken.
Recently, we got a requirement to calculate the sum of Quantity, after grouping the data on 5 columns NDISNumber, SupportDeliveredFrom, SupportNumber, ClaimType and CancellationReason in a custom entity Claim.
Below are the steps we followed to achieve the result:
Initialize 5 variables to hold unique values of each group-by column inside Apply to each action we are going to use further. Please see Note at the end of the post.
Initialize a variable to hold sum of Quantity and a dummy variable for calculation of Quantity as self reference is not supported in PowerAutomate as explained here.
After this step, we are ready for retrieving records with additional filter criteria of unique valued columns.
After this Apply to each action, we’ll get sum of Quantity based on grouped data.
Below is how the entire parent Apply to each action looks like.
After this Apply to each action, we’ll have grouped by data with sum of quantity in NDIS Final array variable.
Furthermore, we had requirement to store the unique data in CSV file in SharePoint. Below are the actions we’ve used to achieve that part.
After performing all the above steps, when we tested our PowerAutomate on the input data, we got our desired output in CSV file.
NOTE: In our requirement, we had to group the data based on 5 columns for which we had to use 5 different variables initially. If the number of columns on which we need to group the data is less or more then accordingly the number of variables will be less or more.
Hope it helps !!
Business Applications communities