Forum Discussion

DarylM's avatar
DarylM
Icon for Helper II rankHelper II
9 years ago
Solved

Sales total to current date from previous year

Hi,  I am struggling to find a way to compare a true total of sales for last year to current date this year.  I am using the "sameperiodlastyear" function, but it returns the entire total for last ...
  • v-yulgu-msft's avatar
    9 years ago

    Hi DarylM,

     

    Please try this formula:

    PYTD Sales =
        CALCULATE (
            [Total Sales],
            PARALLELPERIOD (
                LASTNONBLANK ( 'Unlabeled Jarred Goods Sales'[Date], 1 ),
                -1,
                YEAR
            )
        )

    If you have any question, please feel free to ask.

     

    Thanks,
    Yuliana Gu