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
Hi Team,
I'm trying to convert text to date format however i can't get proper result.
Look like Month have text data type.
i need "MMM-YY" format with M Query (or) DAX.

Thanks,
KV's
Solved! Go to Solution.
@Anonymous , what is data type of month as of now. It is date then you can change display format or try this as new column
New Format = format([month],"MMM-YY")
if it text then try like
New Date = "01-" & left([month],3) & "-" & right([Month],2) // Change data type to date then
New Format = format([New Date],"MMM-YY")
@Anonymous , what is data type of month as of now. It is date then you can change display format or try this as new column
New Format = format([month],"MMM-YY")
if it text then try like
New Date = "01-" & left([month],3) & "-" & right([Month],2) // Change data type to date then
New Format = format([New Date],"MMM-YY")
Hi,
You can split the current format into month & year ( Jan, 20 ) then use Date.Fromtext to add a new column. Once the desired column is ready you can delete Month & Year columns.
Please refer to link.
https://docs.microsoft.com/en-us/powerquery-m/date-fromtext
Appreciate a Kudos! 🙂
If this helps and resolves the issue, please mark it as a Solution! 🙂
Regards,
N V Durga Prasad
Hi,
You can split the current format into month & year ( Jan, 20 ). Use If function in M code to convert month name to number ( Jan to 1, Feb to 2) then use Date.Fromtext to add a new column. Once the desired column is ready you can delete Month & Year columns.
Please refer to the link.
https://docs.microsoft.com/en-us/powerquery-m/date-fromtext
Appreciate a Kudos! 🙂
If this helps and resolves the issue, please mark it as a Solution! 🙂
Regards,
N V Durga Prasad
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.