12 Replies Latest reply: Mar 5, 2015 9:13 AM by Christopher Lofthouse RSS

    How to use variable in set analysis ?

      Hello everyone,


      In my application, there are data for several years and I would like to show in a graph only the last 3 years (current one + 2 laters).


      So I created a variable : vCurrentYear = max(MyYear)    // MyYear is a field in my calendar that goes until the date of execution.



      If I put =$(vCurrentYear)  in a textbox, I do get 2015.


      In my graph, in the expression tab, I have entered  in order to get the sum of Cpt_abt for the past 3 years.





      But I get the message "No data to display".


      If instead, I put

      sum({$<Year_S={">=2013"}>}Cpt_abt)   , I do get my graph.


      I am guessing there must be something wrong with the quotations marks but I cannot find the proper way to write my expression..


      Any ideas ?


      Thank you for your help