Forum Discussion

jdballard30's avatar
jdballard30
Helper II
7 years ago
Solved

ParallelPeriod not Working as Expected

I am using ParallelPeriod and not getting the results I expect. My data is in the table below. I also have a date table, and I marked it as a date table. My date slicer is set to all dates (from 5/10...
  • jdballard30's avatar
    jdballard30
    7 years ago

    After dinner out with my wife and friends, coming home and having a whiskey, it crossed my mind to try:

    Prev Month Qty (Parallel Period) = CALCULATE([Qty This Month], PARALLELPERIOD('Date'[Date], -1, MONTH))

    The difference is putting the measure [Qty This Month] as the first argument instead of SUM('Sales'[Quantity]) in the CALCULATE function. This calculated precisely the result I wanted! And, I realized I've done something similar before. I think I just needed to step away for a bit.


    My reasoning is that if you don't use an existing measure which uses time intelligence as the first argument (such as MTD), it has no idea what period it should parallel. By specifying the original measure with MTD, it knows what month and can determine what the parallel period is.