Dear Forum Members,
I have a graph which works on a single file. I wanted it to work for multiple files but one at a time.
I have tried using ListFile component to list all the files in the source folder but unable to run the graph one file at a time.
Usually there will be a single file but source can contain more than one file a day, so i wanted the graph to tackle multiple files but one by one, I hope this makes sense.
Please if you can kindly help.
Kind regards
Hi,
This is usually solved via Job Flow + Graph combination. Your single file processing graph just needs the file url/name have as a graph parameter - e.g. FILE_URL
Then you use Job Flow where you have ListFiles to provide a list of files which goes into ExecuteGraph where you use Input mapping property to map the incoming file url on your graph’s FILE_URL parameter and set the graph to be executed by this component to be your single file processing graph.
For each file the ListFiles component finds and sends to ExecuteGraph, your graph gets executed and the FILE_URL parameter is filled with that file name/url.
See the attached CloverDX project where both graph & jobflow are present. Run the jobflow.
David
ListFilesExample.zip (5.3 KB)