5 Replies Latest reply: Oct 6, 2017 2:36 AM by Marcus Sommer RSS

    syntax problem less than or equal to addyears with variable

    Bartosz Szczepanski

      hi Guys!

       

      hope you could help me out.

       

      I would like to calculate a sum till a certain time point in previous year, depending on what do I choose in a variable, below is what I came up with, nevertheless it doesn't work, although similar builds in the project do.

       

      Sum({$<

      [Date]= {"$(<=addyears(date('$(vRollingForecastBeginning)'), -1))"}

      >}

      ActualsValue)

       

      The expression alone:

      addyears(date('$(vRollingForecastBeginning)'), -1)

      returns '07/01/2016' and reacts to variable changing correctly, [Date] is formatted as Date in script so the formats should be aligned.


      do you have any ideas?


      thanks in advance,

      Bart