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

Announcements
Qlik Connect 2026! Turn data into bold moves, April 13 -15: Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
Ehumphree
Contributor
Contributor

Separation of data

Hi, trying to separate data between long wait and in time data set.

 =if({<[LW_FLAG]={1}>}Long Wait) 

=if({<[LW_FLAG]={2}>}In Time)

I know I am doing something wrong. Any help is much appreciated.

1 Solution

Accepted Solutions
MayilVahanan

Hi @Ehumphree 

Try like below

 =if([LW_FLAG]=1, 'Long Wait') 

=if([LW_FLAG]=2, 'In Time')

If you want nested if condition, try like below

if([LW_FLAG]=1, 'Long Wait', if([LW_FLAG]=2, 'In Time'))..

If Long Wait & In Time are field, remove the single quotes.

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

View solution in original post

3 Replies
PradeepK
Creator II
Creator II

You are mixing IF condition with Set Expression syntax..

Try :

 if( [LW_FLAG] = 1 , [Long Wait], Null() ) 

 

MayilVahanan

Hi @Ehumphree 

Try like below

 =if([LW_FLAG]=1, 'Long Wait') 

=if([LW_FLAG]=2, 'In Time')

If you want nested if condition, try like below

if([LW_FLAG]=1, 'Long Wait', if([LW_FLAG]=2, 'In Time'))..

If Long Wait & In Time are field, remove the single quotes.

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

Thankyou for your help