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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
anoomohan
Helper I
Helper I

TEXT FORMAT TO DATE FORMAT AND EXTRACT YEAR AND MONTH

Dear all,

 

Please help me to extract month and year from below field, I tried changing using Locale - but getting error while doing so. 

 

anoomohan_0-1705393789115.png

 

1 ACCEPTED SOLUTION

you added extra squares [

Screenshot_1.png

View solution in original post

7 REPLIES 7
anoomohan
Helper I
Helper I

I checked your file, its working perfect, but still I am getting error

 

anoomohan_0-1705425037329.pnganoomohan_1-1705425046283.png

 

you added extra squares [

Screenshot_1.png

anoomohan
Helper I
Helper I

Thanks! 

 

I am getting error - btw, i am sending this from UAE, do we need to change the "en-US"?

pls try this

= "01-"& Text.Combine(
Splitter.SplitTextByCharacterTransition({"A".."Z", "a".."z","-"}, {"0".."9"})([Column1]))

Screenshot_2.pngScreenshot_3.pngScreenshot_4.png

pls show the error

AFTER i entered ur first response - column changed as below 

anoomohan_0-1705409819661.png

 

 

Ahmedx
Super User
Super User

pls  try this

Date.FromText([Column1], [Format = "MMM-yy", Culture = "en-US"])

Screenshot_1.png

Helpful resources

Announcements
PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.