Free Trial

Alteryx Designer Desktop Discussions

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

Formula help Do not want to use Summary tab.

Kinetic_analytics
11 - Bolide

Hello:

Great Analytics folks. Good afternoon. Is it possible to use a formula tab for this formula:

 

 =IF(C22="Branch",F22-G22-J22+I22,IF(C22="Sub",F22-G22-J22+I22-H22,"error"))

I do not want to use Summary tab at this point.

Appreciate your help.

3 REPLIES 3
IraWatt
17 - Castor
17 - Castor

Hey @Kinetic_analytics,

This looks like an excel formula. In alteryx this would be wrote as:

IIF([C22]="Branch",[F22]-[G22]-[J22]+[I22],IIF([C22]="Sub",[F22]-[G22]-[J22]+[I22]-[H22],"error"))

Two points:

- Change IF to IIF

- Add square brackets to column references

 

Do you have any example data and a desired output that you can share for context?

 

Thanks,

Ira

Luke_C
17 - Castor
17 - Castor

Hi @Kinetic_analytics 

 

Seems straightforward, just would need to update your cell references with the field names:

 

IF [C22]='Branch'

Then [F22]-[G22]-[J22]+[I22]

Elseif [C22] = 'Sub'

Then [F22]-[G22]-[J22]+[I22]-[H22]

else "error"

Endif

 

Since you're else is a string and your other clauses are doing mathematical operations you'll probably run into a data type issue. I'd suggest you share some data. 

Kinetic_analytics
11 - Bolide

Thank you. Appreciate your help.

Labels
Top Solution Authors