Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hello,
I have a column like this:
Person1 | 1.00 - Blue; 0.50 - Red |
Person2 | 1.00 - Blue; 0.10 - Green |
Person3 | 1.00 - Green; 0.25 - Red |
Person4 | 0.50 - Red; 0.30 - Green |
I want to do a transformation in PowerQuery that removes the Decimal Number and the Dash:
Person1 | Blue; Red |
Person2 | Blue; Green |
Person3 | Green; Red |
Person4 | Red; Green |
I tried this in Advanced Editor:
GetRidOfNumber =
Table.TransformColumns(
#"Changed Type1",
{
{
"Column2",
(text)=> Text.Remove(text,{"0".."9"})
}
}
)
in
GetRidOfNumber
That gave me:
Person1 | . - Blue; . - Red |
Person2 | . - Blue; . - Green |
Person3 | . - Green; . - Red |
Person4 | . - Red; . - Green |
How do I get rid of the decimal point and hyphen?
TYIA
Solved! Go to Solution.
You can just expand list for 2nd argument, like this: {"0".."9",".","-"} or go with each Text.Select(_,{"a".."z","A".."Z"," "})...
You can just expand list for 2nd argument, like this: {"0".."9",".","-"} or go with each Text.Select(_,{"a".."z","A".."Z"," "})...
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
15 | |
12 | |
8 | |
8 | |
7 |
User | Count |
---|---|
15 | |
13 | |
9 | |
7 | |
6 |