Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Limiting the values in List Box

Hi All,

If some one can answer this question and help me out, my life will become very very easy.

I have a list box which has values from 0 to 100

For my reporting purpose I just need values which are greater 15

If I use default list box then user has to always select values which are greater 15 manually every time.

Is there a way that I can make a list box which show values like this:

0

1

2

3

.

.

.

14

>=15

Plesae reply if there is any way or any other way/object which can handle this requirement.

Thanks,

TA

21 Replies
Not applicable
Author

Mayil,

Thanks for your reply.

By using above expression I am getting the follwoing values in the listbox:

6, 7, 8, ....14, >=5<=15 and >=15

In fact I just want the following  values in my list box:

0, 1, 2, 3, 4, <=5>=14, >=15

I would highly appreciate if you write a expression for these values.

Thanks in advance.

TA

MayilVahanan

Hi

Try this,

=if(test >= 5, '>=5<=14', if(test > 14, '>=15', test))

Hope it helps

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
pgalvezt
Specialist
Specialist

if(FieldName <= 5, '>=5<=14', if(FieldName > 15, '>15', FieldName)

Not applicable
Author

I am sorry its not.

Here is what I am getting here:

0, 1,2,3,4, >=5<=14

There is no value >=15

and If I select >=5<=14 result is not limited to 14 or less in fact it shows the reulst for more than 14 as well

Nicole-Smith

if(FieldName < 5, FieldName,

if(FieldName >= 5 AND FieldName <= 15, '>=5<=15', '>15'))

MayilVahanan

Hi

try this..

if(FieldName < 5, FieldName,

if( FieldName <= 15, '>=5<=15', '>15'))

...

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
Not applicable
Author

Now filter is shown correclty but Still the result is not  coming out correctly.

Now I see the filters as

0,1,2,3,4, >=5<=14, >=15

but when I have slected >=5<=14 some  values are shown which are more than 14 as well.

Any clue why?

Thanks,

MayilVahanan

Hi

    

     Did you use in script or expression? If you did in expression, try this in script for that particular field..

You may be get answer as you expected

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.
Not applicable
Author

You mean before loading the data?

under the relveant table...right?

MayilVahanan

HI

     Like this,

     Load if(FieldName < 5, FieldName,if( FieldName <= 15, '>=5<=15', '>15')) as FieldName, *

     from TableName;

     Hope it helps

Thanks & Regards, Mayil Vahanan R
Please close the thread by marking correct answer & give likes if you like the post.