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.
I am finding the maximum value for sets of filtered rows in a column from the first table.
The following DAX statement gives the appropriate maximum value which goes into the second table.
F Max (ID) =
var d = 'F PL'[RT]
Return
CALCULATE(maxx('F Sub',[F9]),FILTER('F Sub',[RT]=d))
Table = F Sub
ID | F9 | RT |
1 | 12 | 1 |
2 | 5 | 1 |
3 | 87 | 1 |
4 | 64 | 2 |
5 | 35 | 2 |
6 | 22 | 3 |
7 | 43 | 3 |
Table = F PL
RT | F Max (ID) | ID (F Max) |
1 | 87 | 3 |
2 | 64 | 4 |
3 | 43 | 7 |
Column 'ID (F Max)' is the ID from table 'F Sub' associated with the maximum value.
I do not know how to get the values for column 'ID (F Max)'.
Any help would be appreciated.
Thanks
Solved! Go to Solution.
Hi @AGL,
ID (F Max) = LOOKUPVALUE ( 'F Sub'[ID], 'F Sub'[RT], 'F PL'[RT], 'F Sub'[F9], 'F PL'[F Max (ID)] )
Best regards,
Yuliana Gu
Hi @AGL,
ID (F Max) = LOOKUPVALUE ( 'F Sub'[ID], 'F Sub'[RT], 'F PL'[RT], 'F Sub'[F9], 'F PL'[F Max (ID)] )
Best regards,
Yuliana Gu
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
109 | |
98 | |
77 | |
66 | |
54 |
User | Count |
---|---|
144 | |
104 | |
102 | |
88 | |
63 |