What is your goal?
simple automation to take all the files (.txt) from a collection folder at 12:05AM and combine them into 1 txt and save it as yesterdays date in a new folder. then the next automation will process the combined file. Can’t get the files to combine into one. HELP!?!?!?!
What is the problem & what have you tried?
keeps pushing one file at a time and not aggregating them. need a loop to get all the files (up to 50) out of the box and process them as a batch. can’t get it to work. i’ve used every version of aggregator that chat can tell me to use. none work
Error messages or input/output bundles
outputting and overwriting output file
1 Like
Hey there,
can you show the scenario so far? How are you currently getting the files and what do they look like?
I have been going in circles. how this is meant to work is that I have Scenario 1 a collector that collects .txt transcriptions throughtout the day and moves them into a Batch folder. this scenario, is to take that batch at a sceduled time (so files aren’t being added while they are being combined) at 00:15 AM daily. it needs to take ~50 small .txt files in the batch folder and combine them into one .txt file and saved in a new folder, Archive. Scenario 3 will then seperately at 00:45AM it will take teh combined file and run it through a seperate system. all is built except for the combine file, scenario 2. is there a map or best practice for onedrive & .txt?
It will pass files through, but one at a time, and the upload a file at the end just overwrites the file one at a time until done. no combining of files
. been working on this for a full day. Thoughts?
1 Like
@Stoyan_Vatov thank you for looking at this. kind of a crazy loop i have been stuck in for a day now
1 Like
Right off the bat - you don’t need an iterator after a Search module, the search module already iterates the array it produces. Then the source module of any aggregation should be the module producing the extra bundles, in this case the Search module.
Then the text aggregator already returns a text string, what’s the Compose a String module doing?
Then why do you have a sleep module afterwards?
It started off simple and then the ai that was helping me build it spun out. i have had arrays and all kinds of stuff. thought it should just be trigger, identify, read, combine, export… but it needs to loop or hold somewhere so the files just don’t keep spitting out. i have the spine of it but the middle is completely jacked up and ai can’t figure out the combining part.
1 Like
@Stoyan_Vatov is there a best practice or gold standard for how to do this? i can’t find it anywhere in the community 
1 Like
Yeah, AI’s are clueless as how make works and constantly mess up. Do the Make academy instead to see how things work.
Hello, you do not need an iterator module as the output of all those files will process one by one. A suggestion is that you can define a variable before you retrieve the .txt files by adding a “Set Variable” module and perhaps name it something like combinedText. Then for each text file add a “Get Variable” module to get the value of the combinedText variable. Then add another “Set Variable” module. Map the second “Set Variable” module with the output of the “Get Variable” module and the txt variable you are processing. Then create your final combined text file with the output of the second “Set Variable” step. Add a filter between that to make sure it only executes if the Bundle Order position is equal to the Total Number of Bundles.
is there a simple and bulletproof scenario for this? scrape the files at midnight → combine the files → save the output file. It started simple but it ran them through 1 at a time and kept overwriting each other. I can’t seem to get ALL the information in one place. Any ideas? Oh, and thank you for helping out a beginner. 
Yes, delete the iterator module and set the source module of the aggregator to the search module, not the download one.