Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more
Hello,
I've made some changes to my excel data for the sake of uniformity, but now I need to go and adjust my DAX measures to reflect those changes.
Is there a function in Power BI similar to the "Replace" function in excel (picture) so I don't have to manually change every single occurance of this data in my measures?
Thanks in advance for your help!
Solved! Go to Solution.
@Anonymous,
You can achieve this with Tabular Editor (free utility). In the Advanced Scripting tab of Tabular Editor, run the following:
var FromString = "Group 6 MS 404";
var ToString = "Group 6 (MS 404)";
foreach (var m in Model.AllMeasures)
{
m.Expression = m.Expression.Replace(FromString,ToString);
}
Proud to be a Super User!
@Anonymous,
You can achieve this with Tabular Editor (free utility). In the Advanced Scripting tab of Tabular Editor, run the following:
var FromString = "Group 6 MS 404";
var ToString = "Group 6 (MS 404)";
foreach (var m in Model.AllMeasures)
{
m.Expression = m.Expression.Replace(FromString,ToString);
}
Proud to be a Super User!
I've been using this method for a while but suddenly it no longer works, any idea why? Using that exact template fails to replace the values in the expressions i've selected.
https://github.com/TabularEditor/TabularEditor/releases/tag/2.16.6
Proud to be a Super User!
The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!
| User | Count |
|---|---|
| 41 | |
| 38 | |
| 36 | |
| 30 | |
| 28 |
| User | Count |
|---|---|
| 129 | |
| 88 | |
| 79 | |
| 68 | |
| 63 |