Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago
Solved

Convert YYYYMM to Date

Hi all,

 

I have the following column, withthe year and the week number and I'm looking to convert this to a date where the date is the first date of the given week (ie 202304 would be 23/01/2023). Is this possible using DAX and perhaps a new column? 

 

Any help would be much appreciated! Thanks 

  • hi Anonymous 

    try to add a column like this:

     

    DATE = DATE( LEFT([YYYYMM], 4), 1,1) + (RIGHT([YYYYMM],2)-1)*7 + 1

     

     

     

2 Replies

  • hi Anonymous 

    try to add a column like this:

     

    DATE = DATE( LEFT([YYYYMM], 4), 1,1) + (RIGHT([YYYYMM],2)-1)*7 + 1

     

     

     

    • Anonymous's avatar
      Anonymous
      Not applicable

      This worked, thank you so much!