Yash Sharma
Yash Sharma

Reputation: 374

How to NOT IN condition in a filter transformation?

I have a requirement to filter some specific values out from a table, and I tried using the filter transformation like:

ITEM_VALUE NOT IN ('A','B','C')

However, I am getting PM Parse Error syntax error. Is there any way to implement this?

Upvotes: 0

Views: 7973

Answers (2)

Jim Macaulay
Jim Macaulay

Reputation: 5155

Please use below function,

IIF(
(
ITEM_VALUE != 'A' 
OR ITEM_VALUE != 'B' 
OR ITEM_VALUE != 'C') , 'True', 'False'
)

Upvotes: 0

Koushik Roy
Koushik Roy

Reputation: 7397

NOT IN doesn't work like you mentioned. Please try -
IIF (ITEM_VALUE ='A' OR ITEM_VALUE ='B' OR ITEM_VALUE ='C', false,true)
or
ITEM_VALUE <>'A' AND ITEM_VALUE <> 'B' AND ITEM_VALUE <> 'C'
or
NOT IN (ITEM_VALUE,'A','B','C')

Upvotes: 1

Related Questions