Microsoft Fabric Community Conference 2025, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount.
Register nowThe Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.
Hi,
I hope to replace values for all columns no matter how many new columns will be added in the future?
Currently I do it ranging particular columns but will come more new columns over time.
Solved! Go to Solution.
Hi @jeongkim - you can modify your Power Query (M code) script to dynamically apply the replacement logic to every column in the table.
slight adjustment as per the mcode change,
#"Replaced Value" = Table.ReplaceValue(
#"Filtered Rows",
null,
0,
Replacer.ReplaceValue,
Table.ColumnNames(#"Filtered Rows")
)
Locate the step where you are replacing values.
Replace your existing hardcoded column names with the dynamic method shown above.
Save and apply the changes.
Proud to be a Super User! | |
Hi @jeongkim - you can modify your Power Query (M code) script to dynamically apply the replacement logic to every column in the table.
slight adjustment as per the mcode change,
#"Replaced Value" = Table.ReplaceValue(
#"Filtered Rows",
null,
0,
Replacer.ReplaceValue,
Table.ColumnNames(#"Filtered Rows")
)
Locate the step where you are replacing values.
Replace your existing hardcoded column names with the dynamic method shown above.
Save and apply the changes.
Proud to be a Super User! | |
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
If you love stickers, then you will definitely want to check out our Community Sticker Challenge!
User | Count |
---|---|
123 | |
76 | |
71 | |
57 | |
49 |
User | Count |
---|---|
163 | |
83 | |
68 | |
68 | |
59 |