Alteryx Batch Macro Loop
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi There.....
can you help.....i have data where i can only extract a certain number of rows per workflow run...
Therefore i need to run the same workflow multiple times and union each run/loop together to get all data...see below....
Ideally i want a macro to be able to feed in the input and number of loops count and then produce the output...
I want to go from Before to After......and need help to create a batch marco to loop the input the number of times i want
Before workflow attached.....I need the After Workflow as answer........ 
 
Solved! Go to Solution.
- Labels:
- Batch Macro
- Data Investigation
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
@DelData
What is your question?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
How do i create a batch marco to loop the input the number of times i want?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
@DelData
Watch the Macros interactive lesson, it will give you a good idea on what to do.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
no.....what i am after is help for someone to show me how to create a batch macro to push the same input file in a set number of times....this is what will help me
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
no.....what i am after is help for someone to show me how to create a macro to push the same input file in a set number of times....this is what will help me
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Can you explain why you need the same file multiple times? You said you can only extract a certain number of rows.
I know in an excel file you can take only a certain range, you could modify the range for each run if that's what you want.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
if the server says i can get 1000 rows of data and the total rows is 4000
then i need to run my workflow 3 times...I will send request to server and all i will update the row numbers i need to grab...show in bue below
loop1 = rows 1-1000
loop2 = rows 2000-3000
loop3 = rows 3000-4000
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
I see, the batch macro will automtically union the data together before output. Just make sure that each of the "loops" have a unique identifier, as the control parameter of a batch macro will be used to group the data by. So each of your queries will have to be tied to that control parameter/loop. So basically like you have shown there in the blue where they are in their own record. I would personally split it like this:
loop1 | 1 | 1000
loop2 | 1001 | 2000
So that there are three columns that should make it easier to replace the ranges in your quuery. Choose the "loop" column as the control parameter and you should be a long ways with your macro :)
