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! Request now

Reply
ChemEnger
Advocate V
Advocate V

Dynamic result against slicer not calculating correctly

I have successfully set up a slicer to dynamically change a calculation in a matrix table but the row totals are not calculating as desired.

Slicer.png

My calculation is for [Release Strength] where the Strength is either fixed or variable (from a test).  The slicer ([Strength] determines whether to apply the variable result to all markets, no markets or US only. Each row can have one or more Market but only one variable test result and one fixed test result.  I therefore have a measure [Total Release] as:

 

Release Strength =
    VAR
        Strength = SELECTEDVALUE('Strength'[Strength])
    VAR
        Variable = SUM([Test Result])
    VAR
        Fixed = SUM([Fixed Result])
    VAR
        Market = MIN([Market])

    RETURN
        SWITCH(TRUE, Strength ="All", Variable, Strength ="None", Fixed, Strength ="US Only", IF(Market="USA", Variable, Fixed))

The issue I think is that I have to use aggregated values for the measure and the MIN([Market]) means that USA is being ignored if it's not the only market for the release.

 

For example:

MarketFixed ResultVairable Result
Europe262,500288,750
USA850,000935,000

 

If I choose to apply the variable result to US Only I get this, where 262,500 + 935,000 <> 1,112,500.  The other two slicer options are working fine.

Matrix.png

Column totals are working fine, as would be expected.

I am sure there's a simple fix but it's elduing me at the moment!

1 ACCEPTED SOLUTION
ChemEnger
Advocate V
Advocate V

Sorted it.  Quite simply, I added a second measure of:

Total Release = SUMX('Released Goods', [Released Units])
And this is adding correctly across rows and columns

View solution in original post

1 REPLY 1
ChemEnger
Advocate V
Advocate V

Sorted it.  Quite simply, I added a second measure of:

Total Release = SUMX('Released Goods', [Released Units])
And this is adding correctly across rows and columns

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

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!

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
Top Kudoed Authors