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! Learn more
Hey All,
I have the below order number string of data. In most cases there is three 0's prior to the actual order number however sometimes there is not. Is there a function that removes the first three digits only if those first three digits are "000"? Thanks in advance!
Solved! Go to Solution.
@stino123 , a new column in power query
if Text.Start([Column], 3) = "000" then Text.Replace([Column], "000", "") else [Column])
Simple Text.TrimStart() is enough,
| Thanks to the great efforts by MS engineers to simplify syntax of DAX! Most beginners are SUCCESSFULLY MISLED to think that they could easily master DAX; but it turns out that the intricacy of the most frequently used RANKX() is still way beyond their comprehension! |
DAX is simple, but NOT EASY! |
sorry @amitchandak still pretty new to power bi what are the functions for: text.start, Then, text replace, else?
Thanks!
@stino123 , this is power Query code to be used in Transform data module
Text.Start to get first few character , 3 in this case
Text.Replace will replace data in a text
Text.Start, Text.Middle, Text.End: https://www.youtube.com/watch?v=vky4wPqm0O0
https://docs.microsoft.com/en-us/powerquery-m/text-replace
Power Query Replace Value: https://youtu.be/hkZhZbR7Kmk
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.