Hi @sam.mckay,
I got something I was used to doing in Excel, but I really don’t where to start in Power Query.
I have a list of values (3 in this case) in three columns Alpha, Bravo, Charlie.
I need the column name of the maximum value for that row and the maximum value.
I can do it in DAX with some switch instruction, but I think Power Query is the better place.
After I get the max value is there any other option than nested “if then else”?
How does it work?
Record.FieldNames() returns a list of all the column headers
To get a single Name from that List, you can use the position index operator. For example adding {0} would extract the first position in the List. So inside that access operator we lookup the position of that Max Value using this syntax: List.PositionOf(Record.FieldValues(_), [Max Value])