Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

tiklam_dynasys
Contributor

KPI Object show $ and K/M

Hi all,

I would like to show a KPI with dollar and in thousand or million dynamically.

However, i found that it could only show one of them.

Is it possible to show both dynamically?

Best Regards,

Louis

4 Replies
rahulpawarb
Valued Contributor II

Re: KPI Object show $ and K/M

May be this:

='$' &

If(Sum(Value) < 999,

   Sum(Value),

   If(Sum(Value) > 999 AND Sum(Value) < 99999,

      Num(Sum(Value)/1000, '#,##0.##') & ' K',

      If(Sum(Value) > 99999,

      Num(Sum(Value)/1000, '#,##0.##') & ' M')))

Regards!

Rahul Pawar

kaanerisen
Contributor III

Re: KPI Object show $ and K/M

Hi,

numberFormat.png

TEXT(if(Sum(Value) >= 1000000000,  num(Sum(Value)/1000000, '$#.##0,##M', ',', '.'),

if(Sum(Value) >= 1000000,  num(Sum(Value)/1000000, '$#.##0,##M', ',', '.'),

    if(Sum(Value) >= 1000, num(Sum(Value)/1000,  '$#.##0,##K', ',', '.'),

    num(Sum(Value), '$#.##0,##', ',', '.')))))

If you want to use on table object, you don't need to use TEXT function.

Re: KPI Object show $ and K/M

Hi, another option:

=Num(Sum(Value)/Pow(10, Floor(Len(Round(Sum(Value)))-1, 3)), '$#,##0.00')

& Pick(Floor((Len(Round(Sum(Value)))-1)/3)

    , ' K'

    , ' M'

  )

tiklam_dynasys
Contributor

Re: KPI Object show $ and K/M

After using this expression, the conditional color will not work.