Alteryx Designer Desktop Discussions

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

I am trying to use the Multi-Row Formula tool but am not able to get the expected result

bh1789
8 - Asteroid

IF [Employee SID] = [Row+1:Employee SID] OR [Employee SID] = [Row-1:Employee SID] AND [Error Type] = [Row+1:Error Type] OR [Error Type] = [Row-1:Error Type]
THEN 1
ELSE 0
ENDIF

 

 

This is capturing the following 2 entries as a match and returning a "1" when it should be a "0" because the Error Type does not match, only the Employee SID is a match:

Employee SID = 123456

Error Type = Complaint

Employee SID = 123456

Error Type = Privacy

 

 

Can someone please assist?  Thank you!

10 REPLIES 10
binuacs
20 - Arcturus

@bh1789 Can you provide sample input data? 

cjaneczko
13 - Pulsar

Seems to be ok as written. As binuacs mentioned, can you provide a sample data set?

image.png

bh1789
8 - Asteroid

Here is a pic of sample data.  Please note the highlighted 2 rows, the employee SID match but the error type does  not but still returning a "1" as a match

bh1789
8 - Asteroid

Employee SID

Employee SID   D444111
Error Type     Complaint
Employee SID   D444111
Error Type     Privacy
OTrieger
11 - Bolide

@bh1789  The matches, 1, is due to the error type. The above line has the same error type, same with the bottom line, has the same error type. That is what is failing in your formula.

OTrieger
11 - Bolide

the end of your formula
OR [Error Type] = [Row-1:Error Type]

OTrieger
11 - Bolide

Replace the last OR with AND

bh1789
8 - Asteroid

that did not work and instead missed the 9 that should have returned a "1"

binuacs
20 - Arcturus

@bh1789 another way of finding the non-matching error type for the same sid

image.png

Labels