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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
lawadaa
Helper I
Helper I

calculate max and min of a measure

hi everyone

 

I have created a measure that calculated the achievement % . I'm trying to create max, min measure for that column for each sales agent and then find the average achievment% for all categories for the agent.

reference to the example below:

lawadaa_0-1683467454963.png

from the measure [new achiev%],  i want to create maximum achievement measure and return  92% and minimum achievement measure return  61% to return and then the average achievement measure to return 73.19%

 

what i'm trying to calculate from these measures is the sales agent incentive. the rules for the measure calculation is:

-at least one category has achievment % of 90%

-the achievement in all other 3 categories should be at least 70%

 

in the example provided, agent won't get his incentive because he achieved 92% in one category and achieved below 70% in other categories.

4 REPLIES 4
tamerj1
Super User
Super User

Hi @lawadaa 

assuming that the measures will be used in a separate table visual where you slice by [Sales Agent] then you use

Max New Achievement % =
MAXX (
SUMMARIZE ( 'Table', 'Table'[categories summarize], 'Table'[BASE_TYPE] ),
[new achiev %]
)

 

You can just replace MAXX with MINX or AVERAGEX to obtain the other measures

this measure only works in a card visual, when i put in in a table visual it returns the same value of [new achiev %] measure

@lawadaa 
Actually it depend on what do you have in that table. This is what I was trying to clarify in my answer. For example if you have only [Sales Agent] in the table along with the measure it should work. Otherwise, please advise what do have in the table.

this is what i have in my table:

agent id, agent name, category, base type, and the rest are DAX measures 

lawadaa_0-1683534740663.png

 

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.