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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

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
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.