3 Replies Latest reply: Jan 25, 2018 8:36 AM by Sunny Talwar RSS

    YTD Calculation in Table

    Ram Krishna

      Hi,

       

      Can anybody please suggest about YTD calculation in table with filter selection on dimension. I am able to write below code which works fine if value are selected in filter but doesn't work if no value are selected.


      If(GetSelectedCount(Period)=1,

      aggr(rangesum(Below(total sum({<Period=>}Value),0,$(vMonthDiff))),Period),

      aggr(rangesum(Below(total sum({<Period=>}Value),0,Right(Period,2))),Period))

       

      Also, Please find attached QVF.

       

      Thanks in Advance!