We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

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

For loop in alteryx

Jocelynupup
7 - Meteor

Hi there,

 

In this workflow, I want to find the web order of the POS ID. But Alteryx doesn't have the "for loop" function, I was wondering how to realize it in Alteryx.

The rule is we don't stop the loop until the original ID is 0. Then we find the web order based on its ID. I also include the flow chart for a better understanding.

 
table1 
IDoriginal ID
AA0
ABAA
ACAB
ADAC
BA0
BBBA
BCBB
CA0
DA0
DBDA
 
table 2 
Initial IDweb order
AA111
BA112
CA113
DA114

 

result 
POS IDweb order
AC111
BC112
CA113
DB114

 

Thanks,

Jocelyn

 

2 REPLIES 2
apathetichell
20 - Arcturus
CoG
14 - Magnetar

As it turns out, you don't need the batch macro at all. Here is a sample that only utilizes an iterative macro:

Main Workflow:

_Main.png

Iterative Macro:

_Macro.png

Labels
Top Solution Authors