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, the Microsoft Fabric Community team will be offering free DP-600 exam vouchers. Prepare now

Reply
Raul_Cristobal
Regular Visitor

Help with columns with date format

Hello, how can I convert these columns to date? for example: year column = 2009 month column = 12, I want the date 01/12/2019 like this for everyone.
Thank you.

Raul_Cristobal_0-1680110511509.png

Raul_Cristobal_1-1680110520410.png

 

 

1 REPLY 1
PhilipTreacy
Super User
Super User

Hi @Raul_Cristobal 

 

Download example PBIX file

 

In Power Query, add a new Custom Column with this code

 

= Date.From("1/" & Text.From([CDG_MES]) & "/" & Text.From([CDG_ANNO]))

 

 

You can also do it in DAX with this 

 

Date = DATE([CDG_ANNO], [CDG_MES], 1)

 

 

 

regards

 

Phil



Did I answer your question? Then please mark my post as the solution.
If I helped you, click on the Thumbs Up to give Kudos.


Blog :: YouTube Channel :: Connect on Linkedin


Proud to be a Super User!


Helpful resources

Announcements
OCT PBI Update Carousel

Power BI Monthly Update - October 2024

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

September Hackathon Carousel

Microsoft Fabric & AI Learning Hackathon

Learn from experts, get hands-on experience, and win awesome prizes.

October NL Carousel

Fabric Community Update - October 2024

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