cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
ricfernandes
Regular Visitor

Force rollup fields calculation

Dear community,

I'm creating a POC for a client for them to decide whether to go for the Power Platform for replacing a legacy application. The strategy is to use the model-driven approach as far as possible, thus the end result will be a set of business entities which will be manipulated by one or more model-driven apps.

The biggest blocker point so far is that I need several rollup fields to be calculated as soon the data is entered in the entities they refer to. I know we can go to each rollup field and force the value to be updated in the model-driven app directly by hitting the "Update" button that appears next to the field. The thing is that the client wants to have a single button to update all rollup field at once.

Is there a way of doing that? Thanks in advance!

7 REPLIES 7
Highlighted
HSheild Solution Sage
Solution Sage

Re: Force rollup fields calculation

Hi @ricfernandes 

 

You can use a CDS workflow that triggers on the update of any of the fields on the child entity that need to roll-up to the parent entity.  Use the community developed Dynamics 365 Workflow Tools solution and call the Force Calculate Rollup Field workflow activity to trigger the rollup calculation to run.

 

Link to the solution and documentation below

https://github.com/demianrasko/Dynamics-365-Workflow-Tools/blob/master/docs/Force%20Calculate%20Roll...

 

This solution is not the button that you are looking for but may still meet your requirements by recalculating the roll-up fields as the data is entered into the child entity records.

fernanri
New Member

Re: Force rollup fields calculation

Hi @HSheild

 

Thank you very much for your reply.

 

I'm not familiar with Dynamics 365 workflows, thus I'm not sure if the solution can be used as-is in Flow for Power Apps. I will give it a try and let you know about the result.

 

Cheers!

DavidJennaway Responsive Resident
Responsive Resident

Re: Force rollup fields calculation

The previous suggestion only works with a Dynamics 365 workflow, rather than a Flow (Power Automate), but that shouldn't stop you using it 

ricfernandes
Regular Visitor

Re: Force rollup fields calculation

Thanks @DavidJennaway ,

 

That means that the client would need to buy an extra license in order to be able to use Dynamics 365 workflows, right?

DavidJennaway Responsive Resident
Responsive Resident

Re: Force rollup fields calculation

I don't think you need an additional license to use Dynamics 365 workflows. Based on https://powerapps.microsoft.com/en-us/pricing/ , 'custom real-time workflows' refers to Dynamics 365 workflows, and applies to either plan

HSheild Solution Sage
Solution Sage

Re: Force rollup fields calculation

If you have licensing for Model-driven apps then that means you are working on the Common Data Service (CDS). CDS has a workflow tool built in which is Dynamics 365 workflow. CDS workflow and Dynamics 365 workflow are one in the same. However, completely different from Power Automate (Flow) 🙂 I hope that makes sense.
AndreSatziack
New Member

Re: Force rollup fields calculation

Hello my friends,

I have the same challenge.

I have a product grid with all customized fields with quantity * price calculations, but I would like to know how I can calculate the total value for all products added to the grid? In the attached example, I would like to sum all the total values of each product, I tried to do this with Rollup but the custom field I created to add is not listed in the options with SUM 😭

 

I use the Common Data Services solution on my Dynamics 365 and I have Microsoft Power Automate Premium but I haven't figured out how to solve this challenge if anyone can help me I will be super grateful! 🙏

Helpful resources

Announcements
MBAS Gallery 2020

MBAS Gallery 2020

Watch Microsoft Business Applications Summit sessions on-demand.

‘Better Together’ T-Shirt Contest – Winner Announced!

‘Better Together’ T-Shirt Contest – Winner Announced!

And the winner is...

firstImage

New Ranks and Rank Icons released on April 21!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power Apps Community!

Power Platform 2020 release wave 1 plan

Power Platform 2020 release wave 1 plan

Features releasing from April 2020 through September 2020

Users online (6,095)