Advance your Data & AI career with 50 days of live learning, dataviz contests, hands-on challenges, study groups & certifications and more!
Get registeredGet Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
Hello, i'm trying to count the number of white spaces in the beggining of a string in Power Query...
I couldn't find a solution yet.
Here's an example
I have to count just the whitespaces before the text.
Please, help me 🙂
Tks
Solved! Go to Solution.
Hi, @catheprado
Try this:
= Table.AddColumn(<YourPreviousStepName>, "space_cnt", each Text.Length([<YourColumnName>])-Text.Length(Text.TrimStart([<YourColumnName>])))
Hi, @catheprado
Try this:
= Table.AddColumn(<YourPreviousStepName>, "space_cnt", each Text.Length([<YourColumnName>])-Text.Length(Text.TrimStart([<YourColumnName>])))
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
Check out the October 2025 Power BI update to learn about new features.