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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
rbustamante
Helper I
Helper I

How to obtain the max value for several rows with the same id

Hello, I need to calculate in a new colum the max value for the same id within a table.

On the left the origin table and on the right the origin table plus the new calculate column that I need.

rbustamante_0-1614903969687.png

Thanks in advance.

1 ACCEPTED SOLUTION
gvrajesh
Frequent Visitor

Hi @rbustamante 

Create calculated column 

gvrajesh_0-1614911454291.png

 

View solution in original post

4 REPLIES 4
SivaSatya
Regular Visitor

Hello all, I am new to using power BI... I have similar kind of query so i am posting the question here. 

I have similar requirement, in my case i want to check id max date is less than today's date or not. if true, i need to report max date else i need to take max date which is less than today's date.

 

SivaSatya_0-1636637970842.png

 

OutPut:

SivaSatya_1-1636637988121.png 

 

Anonymous
Not applicable

What if I want to do a similar thing, but instead of adding a new column I want to completely eliminate all the rows apart from the ones with a Maximum value per each Id? 

 

Is it possible to do this in a power query, for example, or in some other way? 

rbustamante
Helper I
Helper I

gvrajesh, y ou the man!

gvrajesh
Frequent Visitor

Hi @rbustamante 

Create calculated column 

gvrajesh_0-1614911454291.png

 

Helpful resources

Announcements
June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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