1 Reply Latest reply: Mar 19, 2012 12:53 PM by Henric Cronström RSS

    How to group null values in set analysis as an expression?

    M Paeper



      I found this post here, http://community.qlik.com/message/172382#172382 but its not answering my question, more a workaround.


      How do I group null values in set analysis as an expression so I can be certain that all null values are being treated as a set.


      I have data that has values which I can group into various sets and then the balance is null and I want to group that as well.


      When its not a null value (e.g. the category is M then my code looks like this, and this works fine.


      sum({$<wcGroup={M}>}smProd)  / sum({$<wcGroup={M}>}qty)


      Now when the wcGroup field contents isnt M but its null how can I manage the set?


      I tried syntax


      sum({$<wcGroup={""}>}smProd) / sum({$<wcGroup={""}>}qty)


      sum({$<wcGroup={null}>}smProd) / sum({$<wcGroup={null}>}qty)


      sum({$<IsNull(wcGroup)>}smProd) / sum({$<wcGroup={""}>}qty) 


      and nothing is correct syntax-wise.


      Within set analysis how do I manage null values?