Forum Discussion
mrc_bob
3 years agoRegular Visitor
List.Transform list of columns with return value with function which needs the actual columnName
I am trying for a while to have a dynamic step to transform the data from 1-n columns with the result of a function call. We are working on Dynamics 365 where we have a lot of optionsets. I have...
DennesTorres
Power Participant
3 years agoHi,
I will give some guesses, I hope it provides some ideas to you, sorry in advance if it's a complete miss.
You are trying, inside two level of "each" in power query, to retrieve metadata from the collection, in this case, the columnname. If Power Query had the function NameOf() maybe this would be perfect for what you want, but I think it hasn't yet, it's only in DAX.
Did you thought about turn this logic upside down ? The Table.ColumnNames can retrieve the name of the columns, maybe you could loop through it to retrieve the value of the columns for each row, already having the columnnames in hand?
Kind Regards,
Dennes