5 Replies Latest reply: Aug 23, 2013 10:09 AM by Marcus Sommer RSS

    Problems with number format in Chart

      Using a Chart, I want to display a range of numbers. For formatting purposes i am using the following code:

       

      if((sum([InvoiceNetValue]) > 1000000),
             num(sum([InvoiceNetValue]/1000),'#.##0M;-#.##0M'),
                  if((sum([InvoiceNetValue]) > 10000),
                       num(sum([InvoiceNetValue]/1000),'#.##0K;-#.##0K'),         
      num(sum([InvoiceNetValue]/1000),'#.##,##K;-#.##,##K')))
      
      

       

      This works great. Bigger numbers are expressed in Millions while smaller numbers are expressed as #.##0K.

      However, I want to exclude some values from this chart. I created the following code.

       

      Sum(if([CustomerKey] <> '106180'
           AND [CustomerKey] <> '104300'
           AND [CustomerKey] <> '105680'
           AND [CustomerKey] <> '305000'
           AND [CustomerKey] <> '305500'
           AND [CustomerKey] <> '51062'
           AND [CustomerKey] <> '50339',
      if(([InvoiceNetValue] > 1000000),
        num([InvoiceNetValue]/1000,'#.##0M;-#.##0M'),
             if(([InvoiceNetValue] > 10000),
                  num([InvoiceNetValue]/1000,'#.##0K;-#.##0K'),    
                     num([InvoiceNetValue]/1000,'#.##,##K;-#.##,##K'))),    
      num(0,'#.##,##K;-#.##,##K')))
      
      

       

      The values are correct, however the format doesnt work. It just displays the plain number without the M and K's. How can I fix this?

      It seems that Qlikview completely ignores the num() format.