5 Replies Latest reply: Mar 2, 2018 12:33 PM by Sofia Vaz RSS

    Defining a dimension

    Sofia Vaz

      Hi all,

       

      I'm trying to divide a field by 4 groups. If the field value doesn't fit any group, it shall continue using the original description name. This one will be a 'group' that only have 1 value.

       

      =if(match(AllocTransfOrigMarketCd,'14','15','93'),'AU+CE+CH',

        if(match(AllocTransfOrigMarketCd,'22','23'),'BL+HL+NE',

              if(match(AllocTransfOrigMarketCd,'999','AC','AM','AP','OF','27','.','SET','30','PK','73','GPS','SP','SCO'),'Other',

                  if(match(AllocTransfOrigMarketCd,'91','92','92Z','92L','92M','92O','91Z','91L','91M','91A','91O','92A'),'Overseas',

                      if(match(AllocTransfOrigMarketCd,'17','28'),'UK+IR',

                          AllocTransfOrigMktDescrip)))))

       

      What happens is that qlik sense gets confuse and, for example, if AllocTransfOrigMarketCd= 10, it should be placed in the group of a single value called AllocTransfOrigMktDescrip=PORTUGAL but, instead, currently this group may aggregate much more AllocTransfOrigMarketCd values...

       

      you may see an extract of the division on the image attached.

       

      Do you have any idea what i might be doing wrong?

       

      Thank you!