Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago
Solved

Extract date from date and time

 

I am having trouble extracting the date from the date and time.

I have Start Date and I would like to take date form it. 

 

 

 "StartDay", each Date.From([StartDate]), type date)

 

I would like to get 3/11/2023.

It seems simple, but I can't get it right.

Can someone help me.

  • Hello Anonymous ,

     

    Click at the date time column and then in the add column tab go to the date tab then click at date only and it will give you the date within each row.

     

    If I answered your question, please mark my post as solution so it would appeare to others, Appreciate your Kudos👍

    Follow me on Linkedin

3 Replies

  • Hello Anonymous ,

     

    Click at the date time column and then in the add column tab go to the date tab then click at date only and it will give you the date within each row.

     

    If I answered your question, please mark my post as solution so it would appeare to others, Appreciate your Kudos👍

    Follow me on Linkedin

    • atgeraci01's avatar
      atgeraci01
      Frequent Visitor

      While this does visually cleanup the data point, isn't the time data still present and simply hidden? So if they are specifically referencing date values via dax in a downline use case there could be issues as the data isn't *exactly* as is needed, right?

      The advanced editor entry I used to get to this looks like this:
      Add_Start_of_Day = Table.AddColumn(Changed_Typ", "Start of Day", each DateTime.Date(DateTime.From([DateTime])), type date)