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
stalerik
Helper II
Helper II

DAX help - create column with minimum value so far inside a group

Hello all,

 

I am looking for some help to create a calculated column which holds the minimum value recorded in a group. 

 

I have an Index, Group, and Value column.  The Lowest column should be the minimum value recorded in that group up to the index.

 

I thought this would be easy by filtering the Index to calculate the minumum value (MINX) between Index between Group and current Index but I just get zero.  I think it's finding the minumum value in the whole range insteas of evaluating row by row.

 

Here is some data to explain hwo the lowest should work:

 

IndexGroupValueLowest
232366
242333
252383
262393
272722
282742
292732
302700
312710
323266
333255
343233
353243
363273
373293
383211

 

Thanks for any ideas and help!

1 ACCEPTED SOLUTION
Jihwan_Kim
Super User
Super User

Hi, @stalerik 

 

Please try the below.

 

Picture3.png

 

Lowest CC =
VAR currentgroup = 'Table'[Group]
RETURN
CALCULATE (
MIN ( 'Table'[Value] ),
FILTER (
'Table',
'Table'[Group] = currentgroup
&& 'Table'[Index] <= EARLIER ( 'Table'[Index] )
)
)

 

 

Hi, My name is Jihwan Kim.

 

If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

 

Linkedin: linkedin.com/in/jihwankim1975/

Twitter: twitter.com/Jihwan_JHKIM


If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

View solution in original post

2 REPLIES 2
Jihwan_Kim
Super User
Super User

Hi, @stalerik 

 

Please try the below.

 

Picture3.png

 

Lowest CC =
VAR currentgroup = 'Table'[Group]
RETURN
CALCULATE (
MIN ( 'Table'[Value] ),
FILTER (
'Table',
'Table'[Group] = currentgroup
&& 'Table'[Index] <= EARLIER ( 'Table'[Index] )
)
)

 

 

Hi, My name is Jihwan Kim.

 

If this post helps, then please consider accept it as the solution to help other members find it faster, and give a big thumbs up.

 

Linkedin: linkedin.com/in/jihwankim1975/

Twitter: twitter.com/Jihwan_JHKIM


If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

Thank you very much again @Jihwan_Kim .  This is the second time you have helped me quickly with a problem.  Your solutions have been fantastic and understandable, and I appreciate the help!

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.

August 2025 community update carousel

Fabric Community Update - August 2025

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