In case you missed the announcement: The Alteryx One Fall Release is here! Learn more about the new features and capabilities here
ACT NOW: The Alteryx team will be retiring support for Community account recovery and Community email-change requests after December 31, 2025. Set up your security questions now so you can recover your account anytime, just log out and back in to get started. Learn more here
Start Free Trial

Alteryx Designer Desktop Discussions

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

Help Needed: Skipping Missing Sheets

amnahhussain02
7 - Meteor

Hi all,

I'm trying to build a workflow that:

1) Reads all files within multiple subfolders

2) Reads only the excel documents that contain "725" in their folder name

3) Opens each of these excel files and extracts data from the sheet "M3"

4) This is where it gets complicated as some sheets do not have this tab - I just need them skipped without stopping the workflow.

5) Appends all extracted data into one output excel file.

 

I've tried using Directory > Filter > Dynamic input but I'm running into issues where Alteryx throws errors for files that don't contain the M3 Sheet. 

 

Has anyone done anything similar? Any suggestions? I tried the batch macro approach too.

3 REPLIES 3
JosephSerpis
17 - Castor
17 - Castor

Hi @amnahhussain02 the solution from this post might help you. It has two batch macros the first batch macros reads all the sheets in a file and the second batch macro extracts the data. You can use a filter tool to filter the sheets that have M3 and also filter the the folders that contain 725 from the data from the directory tool using a filter tool as well.

amnahhussain02
7 - Meteor

Thank you so much!!

amnahhussain02
7 - Meteor

How would I change the macro so that it reads multiple sheets instead of the one?

Labels
Top Solution Authors