Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

If statement with data range

I am wondering if it is possible to have this type of if statement:

if (field_b between 0 and 100 than field_d = A), else if (field_b between 101 and 1000 than field_d = B), else if etc.

Can I do it in qlikview?

Many thanks in advance

1 Reply
MayilVahanan

Hi

Try like this

Load *, if(field_b >= and field_b <= 100, 'A', if(field_b >=101 and field_b <= 1000,'B','C')) as field_d 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.