RightNow Communities Logo

RightNow Customer Forums

Register  ·  Sign In  ·  Help
Jump to Page:   1
  Reply   Reply  

"NOT IN" Operator: Is this supported?
Options    Options  
trawls
Enthusiast
Posts: 4


trawls

Message 1 of 4

Viewed 472 times


We have a large list of queues, products, categories, and dispositions and I am finding more and more often now that I woud like to use a "NOT IN" expression as typically I am trying to ignore a shorter list of ids in my expression than the list I want included.  I have had no troubles using the "IN" and "IS NULL / IS NOT NULL" expressions.  But when I try "NOT IN" I get a syntax error message.  We are curretly using Feb '08.

 

My desired expression:

count(distinct if(incidents.status_id IN (3,8,107) & incidents.assgn_acct_id IS NOT NULL & incidents.disp_lvl2_id NOT IN (632,634,635,2066,642,2079),incidents.i_id))

 

Thanks,

 

Tucker

Kudos!
Solved!
Go to the Solution
Go to Solution
10-08-2009 11:09 AM  
  Reply   Reply  

Re: "NOT IN" Operator: Is this supported?
Options    Options  
Bhagwan
Regular Contributor
Posts: 66


Bhagwan

Message 2 of 4

Viewed 469 times


Iam not sure if NOT IN operator is supported by IF() in analytics as there was even no reference of same in FAQ 2809

 

But you can try something like below

 

IF(incidents.disp_lvl2_id <> 632, incidents.i_id, IF(incidents.disp_lvl2_id <> 634, incidents.i_id, IF(incidents.disp_lvl2_id <> 635, incidents.i_id )))

 

It can mimic NOT IN as incident disposition.Let me know if it helps

 

-Bhaggs


 

Bhagwan Singh Mer
Kudos!
10-08-2009 08:42 PM
 
  Reply   Reply  

Re: "NOT IN" Operator: Is this supported?
Options    Options  
RightNow Moderator nlenz
RightNow Moderator
Posts: 218


nlenz

Message 3 of 4

Viewed 463 times


It's probably easier to use the ! operator, i.e. IF(!(incidents.disp_lvl2_id IN (632, 634, 635)), ...
 

Nick Lenzmeier
Product Development

Kudos!
10-09-2009 08:12 AM
 
  Reply   Reply  

Re: "NOT IN" Operator: Is this supported?
Options    Options  
trawls
Enthusiast
Posts: 4


trawls

Message 4 of 4

Viewed 451 times


Thank you Bhaggs for your idea, but I looks as though Nick was the big winner...  Changed it to

count(distinct if((!(incidents.disp_lvl2_id IN (632, 634, 635, 2066, 642,2079)) | incidents.disp_lvl2_id IS NULL) & incidents.status_id IN (3,8,107) & incidents.assgn_acct_id IS NOT NULL, incidents.i_id)) and it worked as desired.

 

Tucker

Kudos!
Accepted Solution
Accepted Solution
10-09-2009 02:03 PM
 
Jump to Page:   1