Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Date Format YYYYMM

Hi,

 

I have a date column which is of format MMMM,YYYY viz. July,2019 for example. This column is also used a  report level filter. 

 

The user wants to see the date as YYYYMM format. I was not able to find this format in the Modeling tab. 

The desired result should be 201907.

 

Please help with the same.

 

Thanks,

Vishy

  • Hi Anonymous  ,

     

    Does that make sense? If so, kindly mark my answer as a solution to help others having the similar issue and close the case. If not, let me know and I'll try to help you further.

     

    Best regards

    Amy

4 Replies

  • v-xicai's avatar
    v-xicai
    Community Support

    Hi Anonymous ,

     

    You can create column like DAX below.

     

    Date Format = FORMAT(Table1[Date],"YYYYMM")

     

    Best Regards,

    Amy

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

     

    • Anonymous's avatar
      Anonymous
      Not applicable

      Hi Amy,

       

      When I use the below DAX formulae, the result comes as 20190705, it includes the day as well. The Date who's format I am trying to change is YYYYMMDD. 

       

      I don't need the day part, only YYYYMM.

       

      Regards,

      Vishy

      • v-xicai's avatar
        v-xicai
        Community Support

        Hi Anonymous ,

         

        Based on my test using the formula below, it works well. You may check it in your side.

         

        Date Format = FORMAT('Table (1)'[Date],"YYYYMM")

         

        Best Regards,

        Amy

         

        If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

  • v-xicai's avatar
    v-xicai
    Community Support

    Hi Anonymous  ,

     

    Does that make sense? If so, kindly mark my answer as a solution to help others having the similar issue and close the case. If not, let me know and I'll try to help you further.

     

    Best regards

    Amy