In case you missed the announcement: The Alteryx One Fall Release is here! Learn more about the new features and capabilities here
ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests after December 31, 2025. Set up your security questions now so you can recover your account anytime, just log out and back in to get started. Learn more here
Start Free Trial

Alteryx Designer Desktop Discussions

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

IF Statement

Palteryxgoal
5 - Atom

IF [Account Code] = "6410090" THEN [2018 E&P Adj]-[Current Balance] ELSE [2018 E&P Adj]+[Current Balance] ENDIF 

 

Please could you show me what's wrong with above IF formula.  I am getting "Invalid Type in Substraction Operator" Error.  I made sure all the components here are V_Wstring so not sure what's still wrong?  

2 REPLIES 2
Kenda
16 - Nebula
16 - Nebula

Hi @Palteryxgoal 

 

If you want to subtract numbers, they must be numerical field types (Int, Double, etc.). Unless you wrap your field name in ToNumber(), you can't subtract string fields.

 

Hope this helps!

Palteryxgoal
5 - Atom

Thanks @BarnesK !  It worked

Labels
Top Solution Authors