I am trying to run a batch macro with a series of files that all have different tab names, so I want to use a dynamic input to first read in all of the tab names. However I'm getting an error that some of the files have a different schema. I'm not sure how this can be given that Alteryx defines the schema of the list of sheet names ?
Solved! Go to Solution.
The error means that some of the tabs have a different schema. For example one has 3 columns and another one has 4 or more.
You could use the Wildcard Input macro from the CReW macros (http://www.chaosreignswithin.com/p/macros.html) to work around this.
Can you explain why the number of columns within a tab affects the list of the sheet names that is being read out?
Thanks for the link, got the crew macros already but hoping to find a solution that is scale-able
You get the error during the import of the sheet names? I thought you get the error in the Dynamic Input tool.
I am (trying!) to use the dynamic input tool to read in the list of sheet names. First I use a directory tool, then a formula to add [FullPath]+"|||<List of Sheet Names>" and then run that through the Dynamic Input tool to get out a full list of the files and tab names
In the end, do you want to read in all the sheets from all the excel files within one folder (and subfolders)? If yes, I'd actually recommend to use the macro @afv2688 posted in this post where I asked about it. This saved my a lot of work when I tried to work with it.
My scenario was sth like
Excel 2016.xlsx (12 sheets)
Excel 2017.xlsx (12 sheets)
Excel 2018.xlsx (12 sheets)
Excel 2019.xlsx (12 sheets)
Excel 2020.xlsx (12 sheets)
and I wanted to import all sheets. His macro does this all in one.
@AbhilashR: no worries, helping does not need an apology 😃
Thank you both - just tried this with my files and I can get to the point I want at the tool before the second macro. Will try with other similar scenarios. Thanks again!
@AbhilashR I tried this but now receiving an error from the macro saying "The field schema for the output changed between iterations". I am also just reading in a list of sheet names so I am unsure how this is possible