Alteryx designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.
Check out our powerful new search update! You can read more here. Please let us know if you have any feedback by creating a topic here.
SOLVED

IF Statement

Highlighted

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?  

Magnetar
Magnetar

Hi @Parthbhavsar 

 

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!

Highlighted

Thanks @BarnesK !  It worked

Labels