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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

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
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors