cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
swebb
Helper I
Helper I

Calendar dates issue

All,

 

I have imported data from Dynamics Business Central to Power BI and I'm having some challenges with the dates. I exported financial data in Excel format from BC, but when I imported in to Power BI, I had to do some data transformation. When doing this, I was unable to set the months as date. I'm not sure why. If anyone has any guidance here, or knows a way to keep the associations with the rest of the data and have a working month column, please let me know. TIA.

 

Edit: Sorry, I don't know if this was very clear or not. Let me try to clarify. When I did my transpose, I ended up with a column corresponding with some financial data that represented totals for each month. The "month" column was set as text and I could not convert it from text to date data type. It just threw a generic error saying it could not convert the data type. I need a solution to pair the month with those totals for each item on the financial report. I hope this made more sense than my original post. Thanks.

1 ACCEPTED SOLUTION
v-jingzhang
Community Support
Community Support

Hi @swebb 

 

A date value is composed with Year, Month, Day. If your Month column only contains month names like "January"/"Jan", it cannot be changed to Date as it doesn't provide valid Year or Day for the month. You need to concatenate the month with Year and Day, then convert the new column to date type. 

For example, add a new column first:

vjingzhang_1-1675750854690.png

Change the data type:

vjingzhang_2-1675750890215.png

 

Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.

View solution in original post

3 REPLIES 3
v-jingzhang
Community Support
Community Support

Hi @swebb 

 

A date value is composed with Year, Month, Day. If your Month column only contains month names like "January"/"Jan", it cannot be changed to Date as it doesn't provide valid Year or Day for the month. You need to concatenate the month with Year and Day, then convert the new column to date type. 

For example, add a new column first:

vjingzhang_1-1675750854690.png

Change the data type:

vjingzhang_2-1675750890215.png

 

Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.

Thank you, this worked for me. 

HotChilli
Super User
Super User

A month is not a date. We'll need some more information to get to the bottom of this.  Please show us what you have and what you want.

Helpful resources

Announcements
T-Shirt Design Challenge 2023

Power BI T-Shirt Design Challenge 2023

Submit your creative T-shirt design ideas starting March 7 through March 21, 2023.

March 2023 Update3

Power BI March 2023 Update

Find out more about the March 2023 update.

March Events 2023A

March 2023 Events

Find out more about the online and in person events happening in March!

Top Solution Authors