Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Howto trigger next subjob from tWaitForFile in loop mode

Hi,
I have a main job that starts with a file handling pre-job build of a tWaitForFile in continue loop mode which is listening on file creation in a certain directory. File creation triggers via iteration tFileCopy that moves the incoming file into a work directory. When finished the file handling pre-job should come back to the main job that OnSubjobOk triggers the next subjob for operation. - That is the idea.
This model works fine if I change the mode of tWaitForFile into exit loop mode; then the pre-job fires the OnSubjobOk event, and the main job starts the next operation's subjob. But in this mode the file handling pre-job with its tWaitForFile will not continue listening for incoming files.
If I change the tWaitForFile's mode into continue loop the file handling pre-job continues listenening for incoming files and moves them, but never fires the OnSubjobOk event (or OnComponentOk - same behaviour...), so the following operation's subjob is never started.
The hole model - main job and all subjobs - use context variables for directory paths, file name patterns etc..

I am using TOS 5.2.1.
Any hints are welcome!
-Thanks in advance,
Frank
Labels (2)
2 Replies
Raghunath
Creator
Creator

try to make job with tWaitForFile as Joblet and give on component ok to next subjob
as Joblet(job with tWaitForFile)----on Component ok-----> sub job
I am using tWaitForFile in similar way. try this it may work
Anonymous
Not applicable
Author

Hi,
thanks for the reply! - Unfortunately we are using the TOS in this project, not the TIS which means there are no joblets available 😞
But anyway, I have found a workaround: I did a little reengineering, and implemented the file handling logic directly into the main job (getting rid of the file handling pre-subjob). Then, when finished with the file handling pre stuff it comes up with a OnComponentOk event which I can use to trigger the next subjob.
Thanks so far!
Frank