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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
dabrooze
New Member

Show MAX over all rows, but keep filter on page

Hi,

I have a table with companie names and their value.

CompanyValue
A10
B50
C30
D20
E10
F5
G60

 

 

I have a page with a report that's showing the max value for each of these companies
CALCULATE ( MAX (  [value] ) , ALL ( [ company] ) )

 

CompanyValueMax value
A1060
B5060
C3060
D2060
E1060
F560
G6060

 

On the page itself is a filter on companies. If I filter out company's G and B, I now still land on a max value of 60.

 

CompanyValueMax value
A1060
C3060
D2060
E1060
F560

 

I'm looking for a DAX formula that's finding the MAX value of the companies that I filtered on the page itself. Based on these companies the output should then return 30.

 

CompanyValueMax value
A1030
C3030
D2030
E1030
F530

 

How to achieve this?

1 ACCEPTED SOLUTION
dabrooze
New Member

Thanks @Uzi2019 and @Kedar_Pande ,

Have used your inputs to land on the following measure that worked for me:

 

CALCULATE (
 MAX ( [Value] ) ,  
     ALLSELECTED ( [Company ) ,
     ALLEXCEPT( [companies table] , [Company] )
)

 

Thanks!

View solution in original post

3 REPLIES 3
dabrooze
New Member

Thanks @Uzi2019 and @Kedar_Pande ,

Have used your inputs to land on the following measure that worked for me:

 

CALCULATE (
 MAX ( [Value] ) ,  
     ALLSELECTED ( [Company ) ,
     ALLEXCEPT( [companies table] , [Company] )
)

 

Thanks!

Uzi2019
Super User
Super User

Hi @dabrooze 

 

Try below dax measure

 

max company = CALCULATE(MAX(company[Value]),ALLSELECTED(company[Company]))
 

Uzi2019_0-1729149756019.png

 

I hope I answered your question!

 

Don't forget to give thumbs up and accept this as a solution if it helped you!!!

DAX Formula:

Max_Filtered_Value = MAX(Table[Value])

This measure calculates the maximum value based on the current filter context applied to the visual. When you filter out companies (like G and B), the max value will only consider the remaining visible companies.

 

💌 If this helped, a Kudos 👍 or Solution mark would be great! 🎉
Cheers,
Kedar
Connect on LinkedIn

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors