Forum Discussion
SatishBadiger
Jun 16, 2022Copper Contributor
IF statement based on multiple columns.
Vendor 1 Vendor 2 Vendor 3 Vendor Master ABC BCD CDE Hi everyone, I'm trying to put up a IF formula for the following scenario. But I'm facing diffic...
SergeiBaklan
Jun 16, 2022Diamond Contributor
If under Power BI you mean transformation in Power Query, you may add custom column as
= Table.AddColumn( Source,
"Vendor Master",
each List.RemoveNulls(Record.FieldValues( _ )){0} )
SatishBadiger
Jun 22, 2022Copper Contributor
I have 15 other columns in my dataset. Will this code still work?
- LorenzoJun 22, 2022Silver Contributor
https://docs.microsoft.com/en-us/powerquery-m/record-fieldvalues and https://docs.microsoft.com/en-us/powerquery-m/record-tolist take a Record ("row" if you prefer) and return a List containing all values from that Record, whatever the number of columns is