2 Replies Latest reply: Sep 11, 2015 2:32 AM by PAUL YEO RSS

    How to add one more var ?

    PAUL YEO

      Hi All

       

      I have learn from below post :-

       

      QS How to combine 2 Revenue and Net Profit Table into 1 Table ?

       

      The solution for above is using script :-

       

      Pick(Match($(Var),1,2),Sum({<rEVENUE={"rEVENUE"}>}Amount)/1000,Sum({<nET_PROFIT={"nET_PROFIT"}>}Amount)/1000)

       

      it look very simple  because i can convert the above script to below :-

       

      Pick(Match($(Var),1,2)

      ,Sum({<rEVENUE={"rEVENUE"}>}Amount)/1000

      ,Sum({<nET_PROFIT={"nET_PROFIT"}>}Amount)/1000)

       

      So in order for me to add one more variable , for example cOST.

       

      Step 1 I go to the variable Add , Value = 3 Label = cOST

      Step 2 I modify the the above script to below :-

       

      Pick(Match($(Var),1,2)

      ,Sum({<rEVENUE={"rEVENUE"}>}Amount)/1000

      ,Sum({<nET_PROFIT={"nET_PROFIT"}>}Amount)/1000)

      ,Sum({<cOST={"cOST"}>}Amount)/1000)

       

      That it , and i am confident it will work fine , But to my surprise it never work. and i don't know why ? May be Andy will know.

       

      Paul