Forum Discussion
Running Total sales orders by customer
Looking for brainstrust help.
I am looking to create a calculated column showing the running total of sales orders by customer.
For example the calculated column below [Nth Sales Order by Customer]
| Date | Sales Order | Customer | Value | Nth Sales Order by customer |
| 10-Jun-19 | 00001 | Tom | $ 5,337 | 1 |
| 17-Jun-19 | 00002 | John | $ 5,219 | 1 |
| 17-Jun-19 | 00003 | John | $ 2,209 | 2 |
| 24-Jun-19 | 00004 | John | $ 9,210 | 3 |
| 1-Jul-19 | 00005 | Tom | $ 5,751 | 2 |
| 1-Jul-19 | 00006 | Tom | $ 4,426 | 3 |
| 8-Jul-19 | 00007 | John | $ 9,859 | 4 |
| 15-Jul-19 | 00008 | Sam | $ 3,838 | 1 |
| 22-Jul-19 | 00009 | Tom | $ 2,767 | 4 |
| 29-Jul-19 | 00010 | John | $ 7,405 | 5 |
Any assistance greatly appreciated.
Karl
Found the solution
Change the Filter to FILTER(ALLEXCEPT(sales, sales[order number]))
6 Replies
- amitchandak
Super User
You can use a quick measure. Right-click on table or measure. Click on quick measure.
Or refer to this
https://community.powerbi.com/t5/Desktop/Cumulative-Total/td-p/43115
Appreciate your Kudos. In case, this is the solution you are looking for, mark it as the Solution. In case this not working, please mark my @ username in reply.
Thanks.- KarlNixon
Advocate I
Hi amitchandak,
Almost gets there - but this gives a running totalfor all values - I'm after a running total for each customer in the data set.
for example for the first sale for Tom, James and Sam they would have the number 1 and for each subsequent sale, 2,3....
Thoughts?
- amitchandak
Super User
I think you need cummlativesub totals
https://community.powerbi.com/t5/Desktop/Calculating-Cumulative-Monthly-Totals/td-p/100756
https://community.powerbi.com/t5/Desktop/Subtotal-YTD-in-Matrix/td-p/324239
https://community.powerbi.com/t5/Desktop/Cumulative-Running-Balance-in-a-Matrix/td-p/490907
Appreciate your Kudos. In case, this is the solution you are looking for, mark it as the Solution.
Thanks.