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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
niculeica
Helper I
Helper I

Need Running Total to ignore Year filter

Hi, community,

 

Having some troubles making Running Total ignore Year slicer. I've read a couple of similar threads, however, I'm still missing something 😞

 

So I have a Transactions table and a Period table based on it [Calendar(Min,Max)]. I've used the below formula to display Running totals per each period, but if I select a specific year in Year filter, the Running total starts with the first period of that year (it's cutting out anything before, not summing it up). I've tried with ALLEXCEPT('_Period'[_Year]) or even with ALL('_Period') and same result (Year field belongs to Period table as well).

 

Any idea what I could go for here?

 

_Revenue running total in Period =
CALCULATE(
    SUM('TransactionsbySegment'[_Revenue]),
    FILTER(
        CALCULATETABLE(
            SUMMARIZE('_Period', '_Period'[_Period Sort], '_Period'[Period]),
            ALLSELECTED('_Period')
        ),
        ISONORAFTER(
            '_Period'[_Period Sort], MAX('_Period'[_Period Sort]), DESC,
            '_Period'[Period], MAX('_Period'[Period]), DESC
        )
    )
)
1 ACCEPTED SOLUTION
mh2587
Super User
Super User

_Revenue running total in Period = //Try this one
CALCULATE(
    SUM('TransactionsbySegment'[_Revenue]),
    FILTER(
        ALL('_Period'),
        '_Period'[_Period Sort] <= MAX('_Period'[_Period Sort])
    )
)

Did I answer your question? If so, please mark my post as a solution!


Proud to be a Super User!




LinkedIn Icon
Muhammad Hasnain



View solution in original post

2 REPLIES 2
mh2587
Super User
Super User

_Revenue running total in Period = //Try this one
CALCULATE(
    SUM('TransactionsbySegment'[_Revenue]),
    FILTER(
        ALL('_Period'),
        '_Period'[_Period Sort] <= MAX('_Period'[_Period Sort])
    )
)

Did I answer your question? If so, please mark my post as a solution!


Proud to be a Super User!




LinkedIn Icon
Muhammad Hasnain



Much appreciate it, @mh2587 !🤝 It did work.

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

AugPowerBI_Carousel

Power BI Monthly Update - August 2024

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

August Carousel

Fabric Community Update - August 2024

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