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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
mark1
New Member

how to get values related to MIN or MAX

I'm hoping this is fairly simple but I've been unable to find any existing reference to my specific question...

 

I understand how to use MIN or MAX to find the minimum or maximum value in a given column, but I'm not sure how to retrieve other values related to the MIN or MAX value. 

 

For example, given the dataset below, the MIN cost is 19.55. How can I create a measure that returns either the date (1/7/2020) or name (Harold) that are associated with this minimum cost value?

 

Similarly, given the dataset below, the MAX cost is 21.92. This cost is associated with two different dates and names. How can I create a measure that lists the names assocuated with this maximum cost, or returns the earliest or latest date associated with this maximum cost?

 

DateCostName
1/1/202020.12David
1/2/202020.15Susan
1/3/202020.18Mike
1/4/202020.18Paul
1/5/202020.18John
1/6/202020.18Mary
1/7/202019.55Harold
1/8/202019.86Ben
1/9/202019.82Chris
1/10/202019.80Julie
1/11/202019.70Peter
1/12/202019.71Henry
1/13/202019.98Matt
1/14/202020.06Jon
1/15/202020.09Bret
1/16/202020.12Byron
1/17/202020.20Leah
1/18/202020.25Oswald
1/19/202020.29Jasmine
1/20/202021.50Robert
1/21/202021.82Donald
1/22/202021.11Erik
1/23/202021.91Richard
1/24/202021.92Tammy
1/25/202021.92Tia
1/26/202021.10Greg
1/27/202020.65Valerie
1/28/202020.62William
1/29/202020.62Kathy
1/30/202020.65George
1/31/202020.66Nathan

 

2 ACCEPTED SOLUTIONS
Greg_Deckler
Community Champion
Community Champion

@mark1 (1) Lookup Min/Max - Microsoft Fabric Community



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

ThxAlot
Super User
Super User

ThxAlot_0-1718228304476.png



Expertise = List.Accumulate(


        {Days as from Today},


        {Skills and Knowledge},


        (Current, Everyday) => Current & Day.LearnAndPractise(Everyday)


)



View solution in original post

2 REPLIES 2
ThxAlot
Super User
Super User

ThxAlot_0-1718228304476.png



Expertise = List.Accumulate(


        {Days as from Today},


        {Skills and Knowledge},


        (Current, Everyday) => Current & Day.LearnAndPractise(Everyday)


)



Greg_Deckler
Community Champion
Community Champion

@mark1 (1) Lookup Min/Max - Microsoft Fabric Community



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

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

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

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