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

Get certified in Microsoft Fabric—for free! For a limited time, get a free DP-600 exam voucher to use by the end of 2024. Register now

Reply
tmitton
Frequent Visitor

Convert month formatted as text to date

I've imported a data set to Power BI Desktop that I do not have any control over (i.e. I can't go into the dataset itself and reformat it). The only "time stamp" the data set contains is a single column formatted as text that contains an abbreviated month. I need to convert this to a date or create a new column that generates a date from this column so that I can create a working relationship with my date table. The new date needs to read as "January 2020" or "February 2020". The data set only contains data for 2020. 

 

 Month Screenshot.png

1 ACCEPTED SOLUTION
tmitton
Frequent Visitor

Not sure if this was the best way, but I went into PQ Editor and replaced each of the 12 separate values with the full month name and year (e.g. replace "Jan" with "January 2020"), and this enabled Power BI to recognize the values as dates when I tried to convert. 

View solution in original post

2 REPLIES 2
Bortolinm
Regular Visitor

Exactly was I was looking for! . Thanks for sharing.

tmitton
Frequent Visitor

Not sure if this was the best way, but I went into PQ Editor and replaced each of the 12 separate values with the full month name and year (e.g. replace "Jan" with "January 2020"), and this enabled Power BI to recognize the values as dates when I tried to convert. 

Helpful resources

Announcements
November Carousel

Fabric Community Update - November 2024

Find out what's new and trending in the Fabric Community.

Live Sessions with Fabric DB

Be one of the first to start using Fabric Databases

Starting December 3, join live sessions with database experts and the Fabric product team to learn just how easy it is to get started.

Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early Bird pricing ends December 9th.

Nov PBI Update Carousel

Power BI Monthly Update - November 2024

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