Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hello All,
I have the following column:
Brand |
Volvo |
2023 07 Volvo |
2023 10 VW |
2022 12 Peugeot |
BMW |
2023 01 BMW |
Peugeot |
Audi |
If the text of the column start with a date, I need to remove only the date, so in my case the first 9 characters (with the bkanks) and only keep the brand names. (When the date appears at the start, the format is Year month)
So the end result would look as below :
Brand |
Volvo |
Volvo |
VW |
Peugeot |
BMW |
BMW |
Peugeot |
Audi |
How could I achieve this in the Power Query ?
Solved! Go to Solution.
Hello, @Chrisjr
let
Source = your_table,
nums = List.Buffer({"0".."9", " "}),
tx = Table.TransformColumns(Source, {"Brand", each Text.TrimStart(_, nums)})
in
tx
Hello, @Chrisjr
let
Source = your_table,
nums = List.Buffer({"0".."9", " "}),
tx = Table.TransformColumns(Source, {"Brand", each Text.TrimStart(_, nums)})
in
tx