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

Shape the future of the Fabric Community! Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions. Take survey.

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.

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

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.