Forum Discussion

codyraptor's avatar
codyraptor
Icon for Resolver I rankResolver I
9 years ago
Solved

Line up PY by Weekday vs CY by Weekday

I need help with a simple format.  Below you can see that my PY and CY dates start on the same row, but last year is WED and this year is THU.  Is there a way to offset this year from last year so th...
  • v-ljerr-msft's avatar
    9 years ago

    Hi codyraptor,



    The dates are coming from a calendar.

    Are PY and CY calculate columns in your calendar table? If that is the case, you should be able to use the formula below to add new calculate column in your calendar table to get the offseted CY. :smileyhappy:

    New PY = 'Calendar'[CY] + WEEKDAY ( 'Calendar'[CY] - WEEKDAY ( 'Calendar'[PY] ) )
    

     

    Regards