0 Replies Latest reply: Oct 24, 2018 9:43 AM by Diego Alejandro Velez Becerra RSS

    Max MonthDiff Value for each Month in set analysis

    Diego Alejandro Velez Becerra

      Hi people, good day to all of you,

       

      I have an application in which I have created a Master Calendar because I needed to calculate variations and accumulated values,

       

      Anyway I'm having trouble with one of the rows in a pivot table in which I want to express the variation between the Current Date column in the table and the Min Date of the selected ones.

       

      What I need for doing this properly is using min period value in every column no matter what, something like this (Min Periods Value):

       

      MonthJanFebMarAprMay
      Period Value1211131022
      Min Periods Value1212121212

       

      Also my master calendar is something like this:

       

      MonthMonthDiff
      Jan0
      Feb0
      Feb1
      Mar0
      Mar1
      Mar2

       

      So if I use MonthDiff = 0 in a Set expression it will use the current month values, if I use MonthDiff =1 it will bring the previous period values etc.

       

      So, what i think will work is setting the max MonthDiff in the set analysis for every Month, I'm trying to do this with the next expression:

       

      =Sum({<MonthDiff={'$(=Max(MonthDiff))'}>} [TOTAL])

       

      But it only displays the value for the ultimate column, I assume it is using the Max value for all of the periods (2 in this case),

       

      Can you help me to fix this expression so it brings max value for each Month.

       

      Thanks a lot, Sorry if my English isn't the best.