Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
JellevdWerff
Regular Visitor

Creating cumulative (running) total which responds to slicer

Hi Everyone,

 

My first Question here on the forum, i have been working with Power-BI now for two days, so i'm a NOOB.

 

I have two SAP HANA Queries, that i joined. One is a stock query, that shows the stock of a depot at this moment (so no date field, just numbers), i created a uniquekey based on several values in my table (country, depot, material, storage location, etc.) and made an leftouterjoin with a query containing all movement registration (these are moving articles going in and out a depot registered per day).

 

I already made a DateFilter based on the datediff of the current date (calculated Column), so end users can select 0 (current_date) and for example 4 as 4 days in the future. This is a calculated column on the registration, some registration require a loading date and some registration require the arrival date. These both dates are combined in the datefilter.

 

Based on the reigstration i also have a calcluated column with expected IN and a column with Expected OUT containing only numbers of products going in or out the depot.

 

 

In the matric i created i now have the depots in the rows, a column with the datefilter and underneath the date i included; Stock, Expected IN and Expected OUT. Now the question of the business is if the Expected OUT and Expected IN can be accumulatted over the days (datefilter)

 

Can anyone help me with this?

 

Here is also a printscreen of the data

printscreen.png 

Thanks in Advance!

 

Regards,

Jelle

2 REPLIES 2
v-yuezhe-msft
Employee
Employee

@JellevdWerff,

What DAX do you use to create cummulative total? To make the cummulative total respond to date slicers, ensure that you use ALLSELECTED() function instead of ALL() function in the DAX.

If you are still unable to get expected result, please share sample data of your table following the guide in this thread.

Regards,
Lydia

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
JellevdWerff
Regular Visitor

Up

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.