This site uses different types of cookies, including analytics and functional cookies (its own and from other sites). To change your cookie settings or find out more, click here. If you continue browsing our website, you accept these cookies.
Even after years of using Alteryx I still seem to somehow avoid using iterative macros when I realize later they are such a great option in my tool chest. What are different ways you have applied using iterative macros in your work? The Supply/Demand examples are well used and variations of it exist and the Collatz Conjecture example is great for learning. Any others?
'Paging' through API calls is perhaps the best example for iterative macro's.
Take the Twitter API for instance; you can only download a maximum of 200 followers for an individual at one time. If that user has more than 200 followers then you have to take a 'next page' indicator within the initial response and loop this back round.
If you take a look at the twitter macros we have developed then you can see what I mean in more detail. Examples below.
I have a workflow that brings in a directory of 30 Excel files, iterates through the files to get the filenames and worksheet names in the first step - then it does a second iteration to bring in the data from ONE of the Excel Worksheets from each file to then push to a Snowflake database
The biggest issue is that since they are shared Excel workbooks the users constantly create duplicate files (when the files get locked) or add columns to the files (like if they feel the need to throw a pivot in the workbook) or just generally change things they shouldn't :)