11 Replies Latest reply: Aug 10, 2010 6:33 AM by Muralidhar Koti RSS

    Using expressions in Graphs

    Muralidhar Koti

      Hi,

      I am new to QlikView and having one issue while designing graphs. The issue is

      I had a graph objects which display the sales data for the selected year and year - 1. The expresssions are as below.

       

       

       

      Sum

       



      ({$<Year={$(=Max(Year))}>} [sales]) and Sum({$<Year={$(=Max(Year)-1)}>} [sales])

      This works absolutely fine. Now I have added one expression to this. Here the ReportOn field is from an inline table which has no relation to the sales table.

       

      if

       

       

      if(ReportOn='Ledger',Sum({$<Year={$(=Max(Year)-1)}>} [Ledger sales]),Sum({$<Year={$(=Max(Year)-1)}>} [sales]))

      This works only when I have not selected any date related filters in my report. If I select a date related filter (say 2009), only the first one works and second one doesn't refresh data. It always gives the [sales] column value.

      Is there anything that I am missing in my expressions?

      Regards,

      Murali

      (ReportOn='Ledger',Sum({$<Year={$(=Max(Year))}>} [Ledger sales]),Sum({$<Year={$(=Max(Year))}>} [sales]))