Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

gameoverzx
New Contributor III

class() function

Hi all,

I want to display a dimension of income using the class() function.

dimensions are as follows:

0=<x<1000

1000=<x<2000

2000=<x<3000

3000=<x<4000

4000=<x<5000

5000=<x<6000

6000=<x<7000

7000=<x<8000

8000=<x<9000

9000=<x<10000

10000=<x<15000

15000=<x<20000

x => 20000

i am able to obtain all the intervals using :

=if(HOUSEHOLDINCOME>10000,

class(HOUSEHOLDINCOME,5000),

class(HOUSEHOLDINCOME,1000))

Having trouble with the last range of x=>20000,

any suggestions would be appreciated.

Regards,

Gaston

1 Solution

Accepted Solutions
MVP
MVP

Re: class() function

Try just putting one more condition like:

= If(HOUSEHOLDINCOME>=20000, 'x => 20000',

   if(HOUSEHOLDINCOME>10000,

      class(HOUSEHOLDINCOME,5000),

       class(HOUSEHOLDINCOME,1000))

)

1 Reply
MVP
MVP

Re: class() function

Try just putting one more condition like:

= If(HOUSEHOLDINCOME>=20000, 'x => 20000',

   if(HOUSEHOLDINCOME>10000,

      class(HOUSEHOLDINCOME,5000),

       class(HOUSEHOLDINCOME,1000))

)