Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Hi,
I have a dataset where I want to calculate a running total of items orderes pr. week and compare it with
items ordered for the same week the year before. I need to see it sorted by the days in advanced the items
are ordered and year vs year. I cant seems to get it to work as it accumulates the numbers for both years.
Anyone who could help?
Solved! Go to Solution.
Hi @Johnrevheim,
In your SPREADSHEET table, the Days before is missing out. While in your wanted result, the Days before values are continious?
Please add ALLEXCEPT function in filter of your formula. And create a matrix used to display what you want.
I try to reproduce, and I use your sample data table.
Create a measure using the formula.
RunningTotal = CALCULATE(SUM(SPREADSHEET[items]),FILTER(ALLEXCEPT(SPREADSHEET,SPREADSHEET[Year]),SPREADSHEET[Days before]>=MAX(SPREADSHEET[Days before])))
Finally, create a matrix, select the days before as Rows level, Year as Column level, please see the following screenshot.
If you have other issues, please feel free to ask.
Best Regards,
Angelia
Thank you very much. The days before is a running series in the original dataset.
Hi @Johnrevheim,
In your SPREADSHEET table, the Days before is missing out. While in your wanted result, the Days before values are continious?
Please add ALLEXCEPT function in filter of your formula. And create a matrix used to display what you want.
I try to reproduce, and I use your sample data table.
Create a measure using the formula.
RunningTotal = CALCULATE(SUM(SPREADSHEET[items]),FILTER(ALLEXCEPT(SPREADSHEET,SPREADSHEET[Year]),SPREADSHEET[Days before]>=MAX(SPREADSHEET[Days before])))
Finally, create a matrix, select the days before as Rows level, Year as Column level, please see the following screenshot.
If you have other issues, please feel free to ask.
Best Regards,
Angelia
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
76 | |
75 | |
54 | |
37 | |
31 |
User | Count |
---|---|
99 | |
56 | |
50 | |
42 | |
40 |