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.
I have multi-string text data in one column separated by unknown number of whitespaces. I want to replace ending special character on 3rd string from left by minus (-) if it ends with plus (+) and vice versa but rest of the string should remain unchanged. I tried split column and replace but couldn't figure it out. Here is an example of input and output column.
Solved! Go to Solution.
pls try this cod
[
f = Text.Range([Input Column],
Text.PositionOfAny([Input Column],{"-","+"},Occurrence.Last),1),
to = Text.Replace([Input Column],f,if f ="-" then "+" else "-")][to]
pls try this cod
[
f = Text.Range([Input Column],
Text.PositionOfAny([Input Column],{"-","+"},Occurrence.Last),1),
to = Text.Replace([Input Column],f,if f ="-" then "+" else "-")][to]
Please provide sample data (with sensitive information removed) that covers your issue or question completely, in a usable format (not as a screenshot). Leave out anything not related to the issue.
https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-...
User | Count |
---|---|
122 | |
69 | |
67 | |
58 | |
52 |
User | Count |
---|---|
187 | |
94 | |
67 | |
63 | |
54 |