Forum Discussion
Anonymous
5 years agoNot applicable
Return a value depending on a max value in another column
Hi, I am looking at some data regarding earthquakes. I can return the highest Magnitude for the selections made, e.g. 8,2 in magnitude. What I want is to also retrieve the date for when it happened,...
- 5 years ago
Hi,
Date/Region Highest Magnitude = VAR MyTable = ADDCOLUMNS ( 'Table 1', "Concat", 'Table 1'[Date] & "|" & 'Table 1'[Region Name] ) RETURN MAXX ( MyTable, IF ( 'Table 1'[Magnitude] = MAX ( 'Table 1'[Magnitude] ), [Concat] ) )Regards
Jos_Woolley
Solution Sage
5 years agoHi,
Date/Region Highest Magnitude =
VAR MyTable =
ADDCOLUMNS (
'Table 1',
"Concat",
'Table 1'[Date] & "|" & 'Table 1'[Region Name]
)
RETURN
MAXX (
MyTable,
IF ( 'Table 1'[Magnitude] = MAX ( 'Table 1'[Magnitude] ), [Concat] )
)Regards
Anonymous
5 years agoNot applicable
Thank you, it works well with minor changes since it was supposed to be split!
Kind regards,
Jari