Forum Discussion

TimmK's avatar
TimmK
Helper IV
4 years ago
Solved

Slow Performance

I follow the star schema having the DIM tables "Item" and "Supplier", as well as the FACT table "Price".   These are the measures I use: Measure 1 =  CALCULATE(MAX('Price'[Start Date]),FILTER('Pr...
  • amitchandak's avatar
    4 years ago

    TimmK , Try with these changes

     

    Measure 1 =

    CALCULATE(MAX('Price'[Start Date]),FILTER('Price','Price'[Start Date]< MAX('Price'[Start Date])))

     

    Measure 2 =
    VAR SL_ = [Measure 1]
    RETURN
    CALCULATE(SUM('Price'[Price]),filter('Price', 'Price'[Start Date]=SL_))