3 Replies Latest reply: Oct 7, 2013 6:06 AM by Jonathan Dienst RSS

    YTD LY figures

    Peter Moyaert

      This is my formula for YTD figures of sales and it is
      working properly :

          

      =SUM({<Jaar_Kalender={'$(vMaxYear)'},%Key_Datum={'<=$(vMaxDate)'},Maand_Kalender=,Dag_Kalender=,MaandJaar_Kalender=>}Waarde_Levering)

       

      Now, I’m trying to calculate the YTD figure of last year
      with following formula :

       

      =SUM({<Jaar_Kalender={'$(vPriorYear)'},%Key_Datum={'<=$(vPriorYearDate)'},Maand_Kalender=,Dag_Kalender=>}Waarde_Levering)

       

      Whereas

                                           


       

      vMaxDate


       

       

      31 aug 2013


       

       

      vMaxDay


       

       

      31


       

       

      vMaxMonth


       

       

      aug


       

       

      vMaxYear


       

       

      2013


       

       

      vPriorMonth


       

       

      jul


       

       

      vPriorMonthYear


       

       

      2013


       

       

      vPriorYear


       

       

      2012


       

       

      vPriorYearDate


       

       

      31 aug 2012


       

       

      But I always get zero figures.

       

       

      Can someone tell me what is wrong in the formula above ?