Forum Discussion

cwayne758's avatar
cwayne758
Helper IV
10 years ago
Solved

SamePeriodLast Year/Contiguous Dates(?)

Hello,   So I have our salespeople in a treemap acting as a slicer over the rest of the canvas. I am showing gross revenue and avg. job revenue brought in for this year. I am comparing it to last y...
  • LarsSchreiber's avatar
    10 years ago

    Hi cwayne758,

     

    it's like the error message tells you: SAMEPERIODLASTYEAR requires a contiguous selection of dates in your slicers. If you use the ctrl. key to select different, non-contiguouse dates, than this function does not work, as you noticed.

     

    Regards,

    Lars

  • kcantor's avatar
    10 years ago

    I have used DATEADD -1 successfully in the past to bypass this particular error when the cause was not immediately apparant. 

    Are you selecting specific date ranges (maybe skipping holidays or weekends)? This would throw off the calculation and cause the error. The error is basically saying that the dates have to be continuious from start to end with no days skipped.

    K