Forum Discussion

Jwhitehead's avatar
Jwhitehead
Frequent Visitor
8 years ago
Solved

Measures with Hierarcical data

I am building a report that compares material purchased in the previous quarter with material purchased in the previous quarter - 1 year prior. The database captures each transaction for all material...
  • Jwhitehead's avatar
    Jwhitehead
    8 years ago

    I got it!

     

    Here is the measure I used to make it work:

     

    SUMX(KEEPFILTERS(VALUES('Filter - MMs Only in Both Periods 1 & 2')),(CALCULATE(AVERAGE('ZPUR_O01 - Periods 1 & 2'[Unit Price (USD)])*[FILTER - PO Qty Period 1 total for Year], KEEPFILTERS(VALUES('ZPUR_O01 - Periods 1 & 2'[Material])))))