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

Join the FabCon + SQLCon recap series. Up next: Power BI, Real-Time Intelligence, IQ and AI, and Data Factory take center stage. All sessions are available on-demand after the live show. Register now

Reply
CP000
New Member

Running Total with multiple items

Dear Community, 

 

I think I have a more complex Running Total challenge.

I have my information arranged by Date, Type and Value. I need to create a monthly running total by date and type.

 

In my business case, I want to show an accumulated chart that's why I need this Running Total.

 
 

Example P BI.PNG

 

Do you know how can this be possible?

Thank you. 

 

1 ACCEPTED SOLUTION
TomMartens
Super User
Super User

Hey @CP000 ,

 

i'm not sure what you mean by running total by date and type. If you select tpye either by slicer, axis label, or row/column header this DAX creates a cumulative value based on type, even if type is not mentioned inside the formula by itself:

 

running total test = 
CALCULATE(
    SUM('Fact Sale'[Quantity])
    , FILTER(
        ALL('Fact Sale'[Invoice Date Key])
        , 'Fact Sale'[Invoice Date Key] <= MAX('Fact Sale'[Invoice Date Key])
    )
)

 

Here is a little screen shot:

image.png

If this does not provide what you are looking for, please give a more detailed explanation what makes the type column special.

 

Regards,

Tom

 



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

View solution in original post

3 REPLIES 3
TomMartens
Super User
Super User

Hey @CP000 ,

 

i'm not sure what you mean by running total by date and type. If you select tpye either by slicer, axis label, or row/column header this DAX creates a cumulative value based on type, even if type is not mentioned inside the formula by itself:

 

running total test = 
CALCULATE(
    SUM('Fact Sale'[Quantity])
    , FILTER(
        ALL('Fact Sale'[Invoice Date Key])
        , 'Fact Sale'[Invoice Date Key] <= MAX('Fact Sale'[Invoice Date Key])
    )
)

 

Here is a little screen shot:

image.png

If this does not provide what you are looking for, please give a more detailed explanation what makes the type column special.

 

Regards,

Tom

 



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

Thank you Tom, can you show me your table in your query editor? 

 

What I mean with Date and Type is:

1/1/2020 1 Budget Target 12,500

2/1/2020 1 Budget Target 25,000

3/1/2020 1 Budget Target 32.500

... and so on.

You see, my table gets complex beacuse I have differente types of data with different values: 1 Budget Target; 2 Forecast; 3 Expected; 4 Actual

 

Hey @CP000 ,

 

if adjust my measure to your table name and column name, it's sufficient to use the date column as axis, the measure as value and the type column as legend, this will create 4 lines.

 

If this is not what you are looking for, create a pbix that contains sample data, but still reflects your data model. Create a sketch how your visual should look like import the sketch to the pbix, upload the pbix to onedrive or dropbox and share the link.

 

Regards,

Tom



Did I answer your question? Mark my post as a solution, this will help others!

Proud to be a Super User!
I accept Kudos 😉
Hamburg, Germany

Helpful resources

Announcements
April Power BI Update Carousel

Power BI Monthly Update - April 2026

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

New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

FabCon and SQLCon Highlights Carousel

FabCon &SQLCon Highlights

Experience the highlights from FabCon & SQLCon, available live and on-demand starting April 14th.