We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

IF OR STATEMENT

KRSANCHEZ
5 - Atom

I am trying to write a simple IF OR statement in Alteryx but I am unsure how. This is the statement as it stands right now:

 

IIF ([Final Classification]='Bad Debt', "Bad Debt",[Owner Step 4])

 

I want to add an OR statement to this however that would be IF Final Classification is Bad Debt OR Billback then Bad Debt, Billback, if it doesn't meet the condition then the result is Owner Step 4.

 

How can I do this?

 

 

2 REPLIES 2
atcodedog05
22 - Nova
22 - Nova

Hi @KRSANCHEZ 

 

One way to do it 

 

IIF ([Final Classification]='Bad Debt', "Bad Debt",
IIF ([Final Classification]='Billback', "Billback",[Owner Step 4]))

 

Or

 

IF [Final Classification]='Bad Debt' THEN 'Bad Debt'
ELSEIF [Final Classification]='Billback' THEN 'Billback' 
ELSE [Owner Step 4] ENDIF

 

Or if you want a single check statement

IF [Final Classification]='Bad Debt' OR
[Final Classification]='Billback' 
THEN 'Bad Debt, Billback'
ELSE [Owner Step 4] ENDIF

 

Hope this is what you are looking for.

binuacs
21 - Polaris

@KRSANCHEZ using IN operator instead  of OR operator is another option

 

IF [Final Classification] IN ('Bad Debt','Billback')
THEN 'Bad Debt, Billback'
ELSE [Owner Step 4] 
ENDIF
Labels
Top Solution Authors