17 Replies Latest reply: Sep 10, 2018 3:44 PM by William Fu RSS

    Current Month vs Previous Month

    Frantz Gonzales

      Hi guys! I have a doubt.


      I have this filter:


      It shows me year and Month. Now, I put on this filter : Year 2018 and Month July .

      Also, I have 2 KPI. Current Month and Previous Month.


      Current Month shows percentage of disponibility of a service from. And Previous Month has to show me percentage of previous month (June ) but my code is not working.




      The sentence to get Current Month is :

      1-(sum({<Disponibilidad={'NO'},[Disp.DeviceName]={'FW_PAITA(.1)'}>} [Disp.Minutos])/(24*31*60))


      Previous Month is:

      1-(Sum({  $< Disp.Num_Fecha = {  $(=Max(Disp.Num_Fecha) - 1)},Disponibilidad={'NO'},[Disp.DeviceName]={'FW_PAITA(.1)'}>}[Disp.Minutos])/(24*31*60))

      I have this fields:



      I used that sentence to previous Month on different sheets(with different data) in the same app and it work it, I don't know why it doesnt work in this sheet.