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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Doohand
Regular Visitor

Remove slicers involvement in a calculation

Hi guys,

 

I have two excel sheets I wan't to see the % diff between. 

Unfortunately they are both very different in the setup why I created some calculations.

 

However, for some reason my Quarter slicer changes my calculation to be smaller than it is. 

See picture:

 

https://imgur.com/D22ptZc

 

Can I make my slicer not affect Q1 but only AMOUNT?

 

Thanks,

 

PS: I can't create a Q1 calculation (summing Jan, Feb and March) from AMOUNT due to its format - I need the slicer.)

1 ACCEPTED SOLUTION
v-frfei-msft
Community Support
Community Support

Hi @Doohand ,

 

To work on it by using REMOVEFILTERS.

Measure = CALCULATE(SUM('Table'[Duration (task hours)]),REMOVEFILTERS('date'[Date]))

 Capture.PNG

 

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.

View solution in original post

4 REPLIES 4
v-frfei-msft
Community Support
Community Support

Hi @Doohand ,

 

To work on it by using REMOVEFILTERS.

Measure = CALCULATE(SUM('Table'[Duration (task hours)]),REMOVEFILTERS('date'[Date]))

 Capture.PNG

 

Community Support Team _ Frank
If this post helps, then please consider Accept it as the solution to help the others find it more quickly.
Mariusz
Community Champion
Community Champion

Hi @Doohand 

 

Most probably is one of the relationships that is affecting the calculation.

You can use something like below considering you have a date dimension.

Measure 8 = 
CALCULATE(
    SUM( table[Q1] ),
    ALL( date dimension table )
)

 

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.



Hi @Mariusz 

 

Thanks! Doesn't seem to work tho as Q1 is a measurement. 

 

I am more interested in if I can make my slicer only focus on óne measurement in a table? 

 

Thanks!

Mariusz
Community Champion
Community Champion

Hi @Doohand 

 

Sure, however, your slicer column needs to be in a separate Table and your relationship inactive.

Then you can invoke it like below by use of USERELATIONSHIP function.

Value2 Afected = 
CALCULATE(
    SUM( 'Table'[Value2] ),
    USERELATIONSHIP( Slicer[Quarter], 'Table'[Quarter] )
)

 

image.png

Best Regards,
Mariusz

If this post helps, then please consider Accepting it as the solution.

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors
Top Kudoed Authors