Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

Unable to create Week End Date in Direct Query

Hi Guys,

 

I am trying to create week end date in PQ. Although I am able to do that it forces me to change the query to 'import'

 

Any workaround as I need it in DQ. Cheers!

 

 

  • I'm not sure you can do it in Power Query but it looks like a DAX calculated column still works:

    EndOfWeek = DatesTable[Date] + 7 - WEEKDAY ( DatesTable[Date] )

4 Replies

  • I'm not sure you can do it in Power Query but it looks like a DAX calculated column still works:

    EndOfWeek = DatesTable[Date] + 7 - WEEKDAY ( DatesTable[Date] )
  • Hi, Anonymous 

    Like Greg_Deckler  and AlexisOlson  mentioned above, you can create a measure to do it.

     

     

     

    Best Regards,
    Community Support Team _ Zeon Zheng


    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

    You could either use formatting to get the days of the week (using ddd) and go from there.

     

    --Nate