Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago
Solved

Running Total Reset after specific column change

Hello,

 

I would like to have a running total that is reset when a value (Job in this case) changes, but keeping another group of information (entryDate, in this case).  I would specifically like to do this in Power Query and not in DAX, if possible.  Below is an example of the input and RunningTotal being the ideal output.

 

JobEntryDateHoursWorkedRunningTotal 
600048/21/2015 12:00:00 AM11 
600047/2/2015 12:00:00 AM12.413.4 
600047/8/2015 12:00:00 AM14.9902828.39027767 
600057/15/2015 12:00:00 AM18.5922218.592222Running Total Reset
600057/18/2015 12:00:00 AM4.747523.339722 
600057/8/2015 12:00:00 AM932.339722 
600057/1/2015 12:00:00 AM29.762562.10222211 
600057/7/2015 12:00:00 AM1880.10222211 
600057/10/2015 12:00:00 AM9.94833390.05055511 
600057/13/2015 12:00:00 AM10100.0505551 
600067/17/2015 12:00:00 AM1010Running Total Reset
600067/20/2015 12:00:00 AM-20.2786-10.27861111 
600067/23/2015 12:00:00 AM21.2941711.01555578 
600066/30/2015 12:00:00 AM8.40444419.42000022 
600067/9/2015 12:00:00 AM928.42000022 
600067/29/2015 12:00:00 AM16.1772244.59722244 

 

Any Advice / Solutions already created?

 

Thanks for the help!

2 Replies

  • patbyr's avatar
    patbyr
    Frequent Visitor

    I did so much research on "running total by group with reset in this column". It was amazing to see there are so many different ones out there but just couldn't find anything close to what I'm trying to accomplish.

     

    Thank you so much for providing a download attachment for it. It helps alot on understanding how you set it up. I did follow step by step as what you provided above BUT would like to add a reset into it. The running total is adding up just like how you have it set up, but I would like for it to reset to 0 once it recognizes the "Yes" in the “Reset?” column and then start adding the running total from there. Here is a screen shot below. The top picture is what I currently have in my power bi query editor while bottom picture is what I would like for it do it. Please let me know if this is possible. Thank you!