Microsoft Fabric Community Conference 2025, March 31 - April 2, Las Vegas, Nevada. Use code FABINSIDER for a $400 discount.
Register nowGet inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.
Dear,
My data:
Here is my issue, I have a table ['MERGED-COST SAVINGS'] with differents columns (i.e granularity) and i want to RETURN a colum G with the cumulative sum of the savings (Column F) in function of the date (Column E)
I wrote this formula:
Using this, I got the wanted graph, see below:
However, when I'm applying any slicer on this graph, for example by SITE or TYPE or SAVING IDEA,
then the curves and the amount ARE NO LONGER CORRECT.
How can I still have my graphs and amount correct AFTER applying any slicer ?
Thanks in advance for your support !
Solved! Go to Solution.
Well, this not Excel.
Assuming that start date is NOT in a relationship with a date dimension table, try this:
Cumulative Sum = VAR ed=MAX('MERGED-COST SAVINGS'[Start date])
RETURN CALCULATE(SUM('MERGED-COST SAVINGS'[Full Year Forecast 2024]), ALL('MERGED-COST SAVINGS'[Start date]), 'MERGED-COST SAVINGS'[Start date]<=ed)
Forget about previous rows, this is not Excel. Cummulative values we do all the time in Power BI. As I do not have your pbix it is hard to guess what;s going on, but if you're using a date dimension in your visual that is filtering that fact table you should use correct the measure to use the date dimension.
Well, this not Excel.
Assuming that start date is NOT in a relationship with a date dimension table, try this:
Cumulative Sum = VAR ed=MAX('MERGED-COST SAVINGS'[Start date])
RETURN CALCULATE(SUM('MERGED-COST SAVINGS'[Full Year Forecast 2024]), ALL('MERGED-COST SAVINGS'[Start date]), 'MERGED-COST SAVINGS'[Start date]<=ed)
Dear,
Thx for your reply. However, I still have the same results than the measure I've posted.
My goal is to create a physical colum on Dax based on Excel example here below:
By doing so, I would have a colum, which a each step (each incremented date), I have the cummulative sum.
Then, I would just need to plot such colum and I will have my raising curve in fct of time.
My guess is that you've created a computed column where you should create a measure. Computed columns are calculated when loading the model and are never affected by filters & slicers....
Dear,
Thx for your reply.
I did create a measure, see screenchot.
Ah OK.
The problem in your measure is most likely the ALL() function overriding all filters, you would want to override only the start date context.
Basicaly,
I want to create (add) a column such as below:
This is easy to do on Excel:
for a date (t), I sum its corresponding amount + the amount on date (t-1)
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code FABINSIDER for a $400 discount!
Check out the February 2025 Power BI update to learn about new features.
User | Count |
---|---|
89 | |
82 | |
65 | |
51 | |
31 |
User | Count |
---|---|
119 | |
113 | |
71 | |
63 | |
46 |