Forum Discussion
carlacervonif
2 years agoFrequent Visitor
Running Total or Cumulative Total column in Power Query
Please please PLEASE make it possible to create a running/cumulative total column in Power Query. The amount of hoops I have to go through to get something as simple as a cumulative value column is c...
BA_Pete
2 years agoSuper User
Hi carlacervonif ,
The reason this topic doesn't seem to get discussed/solved very often is because Power Query isn't really designed for this type of operation. It's a transformation/mashup tool. DAX within a data model is designed to make calculations such as this very fast and efficient.
That being said, it is possible. The trick with doing it in Power Query is doing it with a single table scan, otherwise it can perform very poorly over larger datasets. Here's a good reference to get you started, but it may depend on your specific data structure and needs:
https://gorilla.bi/power-query/running-total/#fast-running-totals
Pete