community
cancel
Showing results for 
Search instead for 
Did you mean: 

Alteryx designer Discussions

Find answers, ask questions, and share expertise about Alteryx Designer.
Community v19.9

The latest release includes several enhancements designed to improve your Community experience!

Learn More
SOLVED

Multi-Row Formula producing negative numbers

Highlighted
Meteor

I have a list of N records (only 1 field) and am dividing the (N+1)th record by the Nth record for all N>1. For N = 1, I set the value to 1. Here is my expression:

 

IF [Field1] = 1  THEN [Field1] = 1 
Else [Field1]/[Row-1:Field1] ENDIf

The output is correct except all the numbers are negative. Any ideas why? 

ACE Emeritus
ACE Emeritus

THEN "[Field] = 1" produces -1, since [Field] does not equal 1.  Just put [Field] there.  :-)

Meteor

Keep forgetting phrases like that evaluate as booleans. Thank you!

Labels