Forum Discussion

owlet0214's avatar
owlet0214
Icon for Helper I rankHelper I
6 years ago
Solved

Difference from previous cel (Additional consultation)

Hello, It is related to a question I previously asked.   https://community.powerbi.com/t5/Desktop/Difference-from-previous-cell/m-p/1091974   I am unable to solve the following problems. I am ...
  • az38's avatar
    6 years ago

    Hi owlet0214 

    your max_test returns the MAX value for all previous period.

    you need smth like

    maxx_test1 = 
    var _maxDate = maxx(filter('Table',[Country/Region]=earlier([Country/Region]) && [DAX_Last date] <earlier([DAX_Last date])),[DAX_Last date])
    
    RETURN
    
    maxx(filter('Table',[Country/Region]=earlier([Country/Region]) && [DAX_Last date] = _maxDate),[count_cum])