Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi All,
I am trying to add extra spaces and a dot to the end of my values in my column. It seems to work in Power Query but when I add it onto a table, Power BI is not honouring it...
For example, lets say I have a table with a column called Fruit. I want the values in there to have around 20 spaces (doesnt have to be exactly 20, just a good amount of spaces) after the text followed by a ".". See sample table/expected output below:
Sample table
Fruit | Expected Output |
Apple | Apple . |
Orange | Orange . |
Kiwi | Kiwi . |
I tried using this formula in Power Query and it works when the editor is open:
= Table.AddColumn(#"Changed Type", "Fruit_Padded", each Text.PadEnd([Fruit],20) & ".")
but when i try to put it in a table, it doesnt work anymore. the "." is placed right after the word (although when i hover over it, I can see the spaces)
Is there a way to fix this?
Appreciate your help.
Solved! Go to Solution.
@m_alireza Use this:
= Table.AddColumn(#"Changed Type", "Fruit Padded", each Text.PadEnd([Fruit],20,Character.FromNumber(160)) & ".")
@m_alireza Use this:
= Table.AddColumn(#"Changed Type", "Fruit Padded", each Text.PadEnd([Fruit],20,Character.FromNumber(160)) & ".")
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
112 | |
100 | |
76 | |
74 | |
49 |
User | Count |
---|---|
146 | |
108 | |
106 | |
90 | |
62 |