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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
drivas771994
Helper II
Helper II

Filter the Same Value in two different ways

Hi, 

 

pbi community_LI.jpg

 

Above is a picture of a report I am working on. The premise of the report is to compare an athlete's individual score to the teams Max and Minimum and show where that falls using the gauge graph. Currently, I am having trouble getting the Max score and the Min score to stay filtered to the entire team's scores. Instead what is happening is that when I select an athlete name. The gauge is filtering itself to only that athlete's scores. Is there a way to get the min and max of the gauge to stay filtered as the entire team but have the score in the middle be that individual filtered athlete's score?

 

 

6 REPLIES 6
v-lili6-msft
Community Support
Community Support

HI,@drivas771994

     After my research, you can use ALLEXCEPT Function  in the formula like this:

for example

Assume that i a data as below:

1.PNG

then use these formula:

Team max = CALCULATE(MAX(Table1[Score]),ALLEXCEPT(Table1,Table1[Sport]))

Team min = CALCULATE(MIN(Table1[Score]),ALLEXCEPT(Table1,Table1[Sport]))

Person max = CALCULATE(MAX(Table1[Score]),ALLEXCEPT(Table1,Table1[Sport],Table1[Name]))

Person min = CALCULATE(MIN(Table1[Score]),ALLEXCEPT(Table1,Table1[Sport],Table1[Name]))

when I select sport is "football" and name is "B"

Result:

2.PNG

here is pbix,please try it.

https://www.dropbox.com/s/9c8hl85e8qnfyjo/Filter%20the%20Same%20Value%20in%20two%20different%20ways....

 

Best Regards,

Lin

Community Support Team _ Lin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
PattemManohar
Community Champion
Community Champion

Just wondering, whether you have tried "Visual Level Filters" or not....





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

Proud to be a PBI Community Champion




I tried to but it does not allow me to filter the values based on text or by the athlete name

Also what if I wanted that filtered by a specific team and date range

robJcenteno
Frequent Visitor

Use ALL() when calculate the max and min.

 

MAX = CALCULATE(MAX('Score'[Games);ALL('Score'[Games]))

 

Using this function, the calculate ignores the filters.

This formula did not work. It still filtered by the individual athlete.

Helpful resources

Announcements
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.