Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
JoeChamp
Frequent Visitor

Get Data - strip out part of text

When I’m in Power BI and Edit data source, I want to add a column referencing another and stripping only a piece of that column, in this case I have a field 2016-01 where I want to strip out the 01 as a Month Column.  I add the Column and get to the formula screen.  A right formula doesn’t work, so I click learn more, which launches me to here

https://support.office.com/en-us/article/Learn-about-Power-Query-formulas-6bc50988-022b-4799-a709-f8...

I then find the link to a reference of formulas, awesome! 

 

https://msdn.microsoft.com/library/Mt253322?ui=en-US&rs=en-US&ad=US

But then I try a few (text.to, text.remove), and they don’t work, e.g. =text.remove([Cost_Plan_Year_Month],1,5), it indicates no syntax errors.

It errors out with this:

Expression Error:  The name 'text.remove' wasn't recognized.  Make sure it's spelled correctly

 

Is there a reference for formulas that will work with Power BI in the Get Data > Edit portion of the tool?

 

More specifically, what formula can I use to strip out the last two characters of this field?

 

 

1 ACCEPTED SOLUTION
hohlick
Continued Contributor
Continued Contributor

Hey Joe.

Please make a note: 'M' language is Case Sensitive

Maxim Zelensky
excel-inside.pro

View solution in original post

2 REPLIES 2
hohlick
Continued Contributor
Continued Contributor

Hey Joe.

Please make a note: 'M' language is Case Sensitive

Maxim Zelensky
excel-inside.pro

Wow...I need coffee.  Never crossed my mind.  Thanks!

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors