Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Im looking to find the maximum value of a column in a table where the table has been filtered. so far the MAX() function is only retuning the maximmum for the entire column unfiltered and im having trouble using the FILTER function to get my desired results. basically i just want the max of the displayed values when the column is filtered, not of the entire data set, thanks.
Solved! Go to Solution.
Here is the sample solution hope it helps (Please download the .pbix file) - emiliaexcels.pbix
To achieve the desired outcome where the maximum value is calculated based on the filtered context, you should use the MAXX function along with the ALLSELECTED function in DAX. The MAXX function allows you to iterate over a table and find the maximum value, while ALLSELECTED respects the current filter context applied in your report.
Sample Dax:
MaxFilteredValue =
MAXX(
VALUES(sample_data[Value]),
CALCULATE(MAX(sample_data[Value]))
)
Here is the sample solution hope it helps (Please download the .pbix file) - emiliaexcels.pbix
To achieve the desired outcome where the maximum value is calculated based on the filtered context, you should use the MAXX function along with the ALLSELECTED function in DAX. The MAXX function allows you to iterate over a table and find the maximum value, while ALLSELECTED respects the current filter context applied in your report.
Sample Dax:
MaxFilteredValue =
MAXX(
VALUES(sample_data[Value]),
CALCULATE(MAX(sample_data[Value]))
)
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!