Hi,
I am using the input data tool, what is the logic to reading in files? Does it take it read in files in alphabetical order? Is there a way to change the order it is read in?
I use the record ID tool on my files and want them to be read in order so my records are numbered correctly.
Hi @wonka1234
I'm kind of assuming you mean starting with a directory tool and not an input here if you're pulling in multiple files? If so then the files are being read in with the oldest files first. You'd be able to apply some sort logic to the files after if you needed them in a different order.
@JamesCharnley No I mean input data. Where you input all data from a directory using something like O:/Alteryx/Community/Test*.xlsx. which would read in files with the same schema.
If you're wildcard unioning then you could take the file name as a field within the input and then sort based on that field later regardless of the order it's being read in. You'd then be able to sort alphabetically in the sort tool
@JamesCharnley I wouldnt say its dynamic input. I dont use that tool. Its input data only with a browse.
I want it to read in files from the directory in alphabetic order
I would suggest to read all the file names you need to read.
Then sort in order you are interested to pull in the datas.
Then use the dynamic input tool.
Many thanks
Shanker V
Yeah apologies I just straight up didn't read your message properly. It's edited to what I think you mean now
Will explain how this will solve the order.
You are reading the file names with Directory tool,
As we are aware that file Test1 will contain Record ID 1 to 20
Test2 will contain Record ID 50 to 60
Test3 will contain Record ID 21 to 49
In the sort, make Test1, Test3 and Test2 as order.
After the dynamic input, you can see all the records pulled in order.
From 1 to 60
Kindly accept this solution if it provided a solution to your question.
Many thanks
Shanker V