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
sarjensystems1
Helper III
Helper III

IGNORE SLICER IN MEASURE.

Capture.PNG

Hii

i need to calculate gross value..gross value=A(category)-selected category

if i select B in the slicer then gross Value should be gross value= -10(26-36)

if i select D in the slicer then gross Value should be gross value= -63(26-89)
irrespective of filter selection category A value should not be changed..

i can't create another table for removing the filter context as i have another slicers as well

how can i do this??

Thanks

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

Hi,

 

Please try this measure:

Measure = CALCULATE(SUM('Table'[Value]),FILTER(ALL('Table'),'Table'[category]="A"))-CALCULATE(SUM('Table'[Value]),FILTER(ALL('Table'),'Table'[category]=SELECTEDVALUE('Table'[category])))

Choose this measure as a card visual and when you select category in slicer, it shows:

51.PNG  52.PNG

 

Best Regards,

Giotto Zhi

View solution in original post

5 REPLIES 5
v-gizhi-msft
Community Support
Community Support

Hi,

 

Please try this measure:

Measure = CALCULATE(SUM('Table'[Value]),FILTER(ALL('Table'),'Table'[category]="A"))-CALCULATE(SUM('Table'[Value]),FILTER(ALL('Table'),'Table'[category]=SELECTEDVALUE('Table'[category])))

Choose this measure as a card visual and when you select category in slicer, it shows:

51.PNG  52.PNG

 

Best Regards,

Giotto Zhi

Stemar_Aubert
Resolver I
Resolver I

@sarjensystems1 

Did you look into editing interactions of your slicers, so one doesn't impact the visual where you insert your measure ?

 

service-reports-visual-interactions 

danextian
Super User
Super User

Hi @Adamtall 

 

Try this:

Measure =
CALCULATE ( SUM ( 'Table'[value] ), 'Table'[category] = "A" ) //value of A
    - SUM ( 'Table'[value] )//less vlaue of other categories









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


Proud to be a Super User!









"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

@danextian 

Hi, I dont need help 😛 its @sarjensystems1 

 

But your forumla dosent make him happy becuse category "A" should be 26 when pressing category A and you will get 0 will your formula.

 

/Adam

Adamtall
Resolver III
Resolver III

Hi,

 

try this measure

 

Measure = var A = CALCULATE(SUM('Table'[Value]) ; 'Table'[category] = "A")
return CALCULATE(IF(MAX('Table'[category]) <> "A" ; A - SUM('Table'[Value]);SUM('Table'[Value])))
 
/Adam

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.