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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
Anonymous
Not applicable

Running totals based on date

Hi,

 

Please find the attached sample data, the requireent is to display the running totals based on month filter selection. 

 

Please find the attachment with requirement explained.https://drive.google.com/file/d/12hOoElZXbH0ZhKWUqOQL7nOItxITkMDa/view?usp=sharing 

 

Regards.

2 ACCEPTED SOLUTIONS
Jihwan_Kim
Super User
Super User

Hi, @Anonymous 

In my opinion, it is better to have a disconnected calendar table, if the slicer is acting differently with the visualization.

Please check the below picture and the sample pbix file's link down below.

The measures are newly written, and those are in the sample pbix file.

 

Picture5.png

 

 

https://www.dropbox.com/s/4jddj5vsnjt8qkt/Finance%20Sample%20Data%20-%20Copy.pbix?dl=0 

 

Hi, My name is Jihwan Kim.

 

If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

 

Linkedin: linkedin.com/in/jihwankim1975/

Twitter: twitter.com/Jihwan_JHKIM


If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

View solution in original post

v-xiaotang
Community Support
Community Support

Hi @Anonymous 

You can take steps bellow for reference:

  1. Create a calendar table

v-xiaotang_0-1620117511407.png

Calendar Table = SUMMARIZE( financials, financials[Date])

Keep them disconnected

v-xiaotang_1-1620117511412.png

  1. Create the measures

 

myMeasure =
VAR _max = SELECTEDVALUE('Calendar Table'[Date])
VAR _firstdate =
    CALCULATE (
        FIRSTDATE ( financials[Date] ),
        FILTER ( ALL ( financials ), financials[Date].[Year] = YEAR ( _max ) )
    )
RETURN
    IF (
        SELECTEDVALUE ( financials[Date] ) > _max,
        BLANK (),
        CALCULATE (
            SUM ( financials[ Sales] ),
            KEEPFILTERS (
                FILTER (
                    ALL ( financials ),
                    financials[Date] >= _firstdate
                        && financials[Date] <= _max
                )
            )
        )
    )

 

result:

v-xiaotang_2-1620117511415.png

v-xiaotang_4-1620117618722.png

Hope it helps.

 

Best Regards,

Community Support Team _ Tang

If this post helps, please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
v-xiaotang
Community Support
Community Support

Hi @Anonymous 

You can take steps bellow for reference:

  1. Create a calendar table

v-xiaotang_0-1620117511407.png

Calendar Table = SUMMARIZE( financials, financials[Date])

Keep them disconnected

v-xiaotang_1-1620117511412.png

  1. Create the measures

 

myMeasure =
VAR _max = SELECTEDVALUE('Calendar Table'[Date])
VAR _firstdate =
    CALCULATE (
        FIRSTDATE ( financials[Date] ),
        FILTER ( ALL ( financials ), financials[Date].[Year] = YEAR ( _max ) )
    )
RETURN
    IF (
        SELECTEDVALUE ( financials[Date] ) > _max,
        BLANK (),
        CALCULATE (
            SUM ( financials[ Sales] ),
            KEEPFILTERS (
                FILTER (
                    ALL ( financials ),
                    financials[Date] >= _firstdate
                        && financials[Date] <= _max
                )
            )
        )
    )

 

result:

v-xiaotang_2-1620117511415.png

v-xiaotang_4-1620117618722.png

Hope it helps.

 

Best Regards,

Community Support Team _ Tang

If this post helps, please consider Accept it as the solution to help the other members find it more quickly.

Jihwan_Kim
Super User
Super User

Hi, @Anonymous 

In my opinion, it is better to have a disconnected calendar table, if the slicer is acting differently with the visualization.

Please check the below picture and the sample pbix file's link down below.

The measures are newly written, and those are in the sample pbix file.

 

Picture5.png

 

 

https://www.dropbox.com/s/4jddj5vsnjt8qkt/Finance%20Sample%20Data%20-%20Copy.pbix?dl=0 

 

Hi, My name is Jihwan Kim.

 

If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

 

Linkedin: linkedin.com/in/jihwankim1975/

Twitter: twitter.com/Jihwan_JHKIM


If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors