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
bo_wang5
Helper II
Helper II

Dynamic Waterfall Comparing Current Period to Last Period with Breakdown

I'm trying to create a visual which shows current month vs. last month's sales amount broken down by dealer.  This visual has to update on a monthly basis based on the current sales data's max date.  right now I'm filtering manually, there must be a better way to do this.  

 

bo_wang5_1-1631939166087.png

 

1 ACCEPTED SOLUTION
Icey
Community Support
Community Support

Hi @bo_wang5 ,

 

You can use a measure as a filter like so:

Measure =
VAR PreviousMonthStart =
    EOMONTH ( TODAY (), -2 ) + 1
VAR CurrentMonthEnd =
    EOMONTH ( TODAY (), 0 )
RETURN
    IF (
        MAX ( 'Table'[Date] ) >= PreviousMonthStart
            && MAX ( 'Table'[Date] ) <= CurrentMonthEnd,
        1
    )

MEASURE FILTER.PNG

 

 

Best Regards,

Icey

 

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

View solution in original post

2 REPLIES 2
Icey
Community Support
Community Support

Hi @bo_wang5 ,

 

You can use a measure as a filter like so:

Measure =
VAR PreviousMonthStart =
    EOMONTH ( TODAY (), -2 ) + 1
VAR CurrentMonthEnd =
    EOMONTH ( TODAY (), 0 )
RETURN
    IF (
        MAX ( 'Table'[Date] ) >= PreviousMonthStart
            && MAX ( 'Table'[Date] ) <= CurrentMonthEnd,
        1
    )

MEASURE FILTER.PNG

 

 

Best Regards,

Icey

 

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

ahp-sig
Frequent Visitor

This doesnt seem to work in latest version of PBI anymore. Downloaded the file but it doesnt produce any results in the chart. ☹️

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.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

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

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.