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

Change measure results depending on a slicer using Power BI

I'm making a report using Power BI. The data that I'll show is the commulative ammount of a turnover. Inside the data source I've this data.

MonthAmmountFilter
117option A
115Option B
116

Option C

212

Option A

214

Option B

213

Option C

317

Option A

318

Option B

316

Option C

I've this on the report:

qlGE3.png

For the filter column I'll create a slicer and when there's nothing selected the sum of all the options must be show in the graph, when selected on or multiple only the selections must be shown in the graph. To create the graph I've created this measure:

Commulative ammount = 
CALCULATE(
    SUM('Turnover'[Ammount]),
    FILTER(
        ALL('Turnover'), 
        'Turnover'[Month] <= MAX('Turnover'[Month])
    )
) 

In this situation, when I select an option from the filters, the graph doesn't change the data. How could I do this?

1 ACCEPTED SOLUTION
Anonymous
Not applicable

I think you should use ALLSELECTED instead of ALL for the desired results:

Commulative ammount = 
CALCULATE(
    SUM('Turnover'[Ammount]),
    FILTER(
        ALLSELECTED('Turnover'), 
        'Turnover'[Month] <= MAX('Turnover'[Month])
    )
) 

View solution in original post

5 REPLIES 5
amitchandak
Super User
Super User

@Anonymous , use allselected

 

Commulative ammount = 
CALCULATE(
    SUM('Turnover'[Ammount]),
    FILTER(
        ALLSELECTED('Turnover'), 
        'Turnover'[Month] <= MAX('Turnover'[Month])
    )
) 
Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
mahoneypat
Microsoft Employee
Microsoft Employee

Try ALLSELECTED() instead of ALL().

 

If this works for you, please mark it as the solution.  Kudos are appreciated too.  Please let me know if not.

Regards,

Pat





Did I answer your question? Mark my post as a solution! Kudos are also appreciated!

To learn more about Power BI, follow me on Twitter or subscribe on YouTube.


@mahoneypa HoosierBI on YouTube


ThoSch-Ger
Helper I
Helper I

Do you get the Options out of the table 'Turnover'?

In that case try:

 

Commulative ammount = 
CALCULATE(
    SUM('Turnover'[Ammount]),
    FILTER(
        ALLEXCEPT('Turnover', 'Turnover'[Filter] ), 
        'Turnover'[Month] <= MAX('Turnover'[Month])
    )
) 
FarhanAhmed
Community Champion
Community Champion

Commulative ammount = 
CALCULATE(
    SUM('Turnover'[Ammount]),
    FILTER(
        'Turnover', 
        'Turnover'[Month] <= MAX('Turnover'[Month])
    )
)






Did I answer your question? Mark my post as a solution! Appreciate your Kudos!!

Proud to be a Super User!




Anonymous
Not applicable

I think you should use ALLSELECTED instead of ALL for the desired results:

Commulative ammount = 
CALCULATE(
    SUM('Turnover'[Ammount]),
    FILTER(
        ALLSELECTED('Turnover'), 
        'Turnover'[Month] <= MAX('Turnover'[Month])
    )
) 

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