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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
dmilardo_au
Frequent Visitor

How to get a filterd table based of highest values and an other tabels column?

Hi, I have two tables.

Table 2 filters Table 1 in my modell in PowerBi. I want to get a new table which contains all rows of table 1 with the highest result_id filtered by different the rivet_point's which are in a column of table 2. There are many result_id's for each rivet_point. But I want only the last result_id for each rivet_point which means the highest result_id for every rivet_point.

 

I hope you can help me

 

Table 1:

dmilardo_au_0-1686130694686.png

 

Table 2:

dmilardo_au_1-1686130741711.png

 

 

 

2 REPLIES 2
amitchandak
Super User
Super User

@dmilardo_au , Assuming both are related based on rivet_point

a new table = filter( addcolumns( Table1,

"Col1" = maxx(filter(Table2, Table1[rivet_point] = table2[rivet_point]), Table2[result_id])  )

, Table2[result_id] = [Col1])

 

Thanks for your response @amitchandak.

I tried it but I get the warning that ADDCOLUMNS needs 3 arguments.

 

Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

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.