1 Reply Latest reply: Jun 13, 2018 5:48 PM by Christophe Brault RSS

    Sum behaves weirdly - sample inside

    Justin Dallas

      Hello Folks,


      While debugging another problem, I ran into something that I was unfamiliar with.  Apparently, if I have a SUM measure, with a condition set to a value that doesn't exist, Qlik will ignore it and sum over the entire field.  For instance.


      LOAD *, 
      Null() AS 'payType'
      LOAD * Inline
      'employeeId', 'amount'
          1, 200
          1, 100
          1, 36


      Now as we see, the 'payType' field is null.  But when I have this set analysis in the UI, I am left astonished.


      SUM({<payType={'Foo'}>} amount)




      Does anyone know why it's summing over everything? when Null() != 'Foo' ?


      Any help is greatly appreciated.