Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
I'm attempting to migrate a dashboard from Tableau to PowerBI, and I'm unsure how to implement a specific feature.
Basically, if I have a column for sales for the months of Jan Feb Mar, I need a column that shows cumulative sales, at the same time, if I filter to only show Feb, the cumulative should contain Jan+Feb. Likewise, if I only filter to show March, it should show the cumulative sales of all 3 months.
Below is a Tableau forum post of what I want to happen.
https://community.tableau.com/thread/187499
Solved! Go to Solution.
Hi @Tony5,
Please create another table named "Month" including month, there is no ralationship between table Month and your sales table.
1. Create a sclier including Month[month] column.
2. Create a measure to calculate the running total using the formula below.
running total = VAR mm=SELECTEDVALUE(Month[Month]) Return CALCULATE(SUM(Test[sales]),FILTER(Test,Test[Month]<=mm))
3. Please see the screenshot, when you click 1, it disply the sum sale of jan, when you click 2, it disply the sum sale of jan+feb. You will get expected result.
Please download the attachment for more details.
Best Regards,
Angelia
Hi @Tony5,
Please create another table named "Month" including month, there is no ralationship between table Month and your sales table.
1. Create a sclier including Month[month] column.
2. Create a measure to calculate the running total using the formula below.
running total = VAR mm=SELECTEDVALUE(Month[Month]) Return CALCULATE(SUM(Test[sales]),FILTER(Test,Test[Month]<=mm))
3. Please see the screenshot, when you click 1, it disply the sum sale of jan, when you click 2, it disply the sum sale of jan+feb. You will get expected result.
Please download the attachment for more details.
Best Regards,
Angelia
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
118 | |
104 | |
77 | |
73 | |
52 |
User | Count |
---|---|
145 | |
109 | |
109 | |
90 | |
64 |