Alteryx Designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.
ALTER.NEXT:

Join us on Dec 2 for a half-day virtual analytics + data science event!
US & CA customers only

SAVE YOUR SPOT
It's the most wonderful time of the year - Santalytics 2020 is here! This year, Santa's workshop needs the help of the Alteryx Community to help get back on track, so head over to the Group Hub for all the info to get started!
SOLVED

IF AND Statement

Highlighted
5 - Atom
I'm trying to write and IF and Statement: IIf (Balance 12.31.2018=0 AND Balance 6.30.2018<>0, "New", "No") but it gives me an error. I'm trying to say that as long as my 12/31 balance is 0 and my 6/30 balance is anything other than 0 to return "New". Any help would be greatly appreciated!
Highlighted
Alteryx Certified Partner

Hey @kschulke 

 

What error do you get?

 

Your statement looks good but without more information its hard to diagnose

Highlighted
Alteryx Certified Partner
Alteryx Certified Partner

Hi @kschulke 

 

I think you're probably getting the operator wrong.

 

 IIf (Balance 12.31.2018=0 AND Balance 6.30.2018!=0, "New", "No") 

Use != instead of <>

 

Also, check for datatypes. 

 

Cheers,

Highlighted
5 - Atom
It says "An expression cannot end with an operator" I'm guessing it doesn't like the <> but not sure how to fix it?
Highlighted
5 - Atom
Thanks so much! Works perfect!
Highlighted
14 - Magnetar

I found two issues here:

You need brackets around your field names (since there is a space in them), and Alteryx does not use <> as "Not equals", instead it uses !=

 

IIf ([Balance 12.31.2018]=0 AND [Balance 6.30.2018]!=0, "New", "No")

Labels