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.
This article will show you a step by step guide to read in your data. The key here is that in the interface designer (view>>interface designer) you can go to the wrench Icon and change the output mode to 'auto config on name'. This will allow different fields to carry through without it erroring as you have been experiencing.
I would just download the sample module at the bottom of that article and change the directory tool to your dataset.
I have attached the batch macro which will replace your dynamic input currently. You will feed in the full path into this tool.
Alternatively you can use @Joe_Mako approach below.
Probably to late in the game to be useful to you but may help others who find this thread. the error you are getting on inconsistent schema can come from multiple sources. Jordan at Alteryx gave great assistance in regard to issues relating to sheet name variances. another source that can be independent of file type, xlsx, csv, yxdb, is the actual field definitions. In excel in particular assumptions are made by excel as to the data types and lengths assigned and Alteryx generally accepts those assignments so if one file was assigned a number data type due to the type of data it contained in that file yet another file assigned the same field as string due to alphanumeric data being present in that column of that specific file then you have inconsistent schema's.
This can also throw you off when you read a file of parameters into a Dynamic Input and use String Replacement in the SQL. If the length of the string changes in one of the variables used as a source for the string value then it will cause an inconsistent schema error also. In this scenario Alteryx apparently needs the input string to be the exact same size in each case. I used a formula to pad the string with blanks to get around this.
So it may be that the file names may vary due to "Tab" names for excel based files but for any file it may be the perceived data types coming into the Dynamic Input changed from one file to another or finally if using SQL string Replacement the variable values must have the same length.