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
Anonymous
Not applicable

ignore specific slicer in measure

hi,

I created a new measure using summarize. I want the station slicer is not to change the result of the ntrips measure. I used the removefilters command, but I could not achieve the desired result.

 
NTrips =
var a = SUMMARIZE('Table','Table'[LINE],'Table'[DIRECTION],'Table'[DATE],"ntrips", CALCULATE(MAX('Table'[TRIPS]),REMOVEFILTERS('Table'[STATION])))
return
sumx(a,[ntrips]
)

Sample file is here https://1drv.ms/u/s!AsQNupGZsOP-sRIvpROXCVhKtkjk?e=8nlfpQ

scr1.jpg

 

 

scr.jpg

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous , Try like

 

NTrips =
var a = SUMMARIZE(calculateTable('Table', all('Table'[STATION]) ),'Table'[LINE],'Table'[DIRECTION],'Table'[DATE],"ntrips", CALCULATE(MAX('Table'[TRIPS])))
return
sumx(a,[ntrips]
)

 

 

Best in such case to use independent table for STATION

 

Power BI Abstract Thesis: Need of an Independent Table in Power BI: https://youtu.be/lOEW-YUrAbE

View solution in original post

3 REPLIES 3
amitchandak
Super User
Super User

@Anonymous , Try like

 

NTrips =
var a = SUMMARIZE(calculateTable('Table', all('Table'[STATION]) ),'Table'[LINE],'Table'[DIRECTION],'Table'[DATE],"ntrips", CALCULATE(MAX('Table'[TRIPS])))
return
sumx(a,[ntrips]
)

 

 

Best in such case to use independent table for STATION

 

Power BI Abstract Thesis: Need of an Independent Table in Power BI: https://youtu.be/lOEW-YUrAbE

Anonymous
Not applicable

hi @amitchandak 

After creating a independent station table, the issue was resolved. thank you so much.

Anonymous
Not applicable

thx for quick answer but ntrips value change  when i select multiple date with station.

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