Wait for directory to have file(s)
Moderators: chulett, rschirm, roy
Wait for directory to have file(s)
I have a sequencer where the starting point is wait for file activity ,,, i have specified a path name and file name and only when that file appears the job runs...
but if the need is to start the job whenever file(s) land(appear) in a particular directory trigger the job ,,, can this be done ,,, going through the documentation i didnot find any such clause/condition
can you please help me find an answer to this
Thanks
but if the need is to start the job whenever file(s) land(appear) in a particular directory trigger the job ,,, can this be done ,,, going through the documentation i didnot find any such clause/condition
can you please help me find an answer to this
Thanks
-
- Premium Member
- Posts: 1255
- Joined: Wed Feb 02, 2005 11:54 am
- Location: United States of America
Hi Nsg,
You can also use mutliple Wait-for-file activities and then follow it up with a sequencer having the "any" or "all" option. So, if any one of the file appears then you can trigger your job activities.
Or if you need all the files to be present, then select the "all" option in the sequencer. This way you can trigger your job activities only when all the files have appeared.
Kumar's suggestion also is interesting. Did you try it out?
Thanks,
Naveen.
You can also use mutliple Wait-for-file activities and then follow it up with a sequencer having the "any" or "all" option. So, if any one of the file appears then you can trigger your job activities.
Or if you need all the files to be present, then select the "all" option in the sequencer. This way you can trigger your job activities only when all the files have appeared.
Kumar's suggestion also is interesting. Did you try it out?
Thanks,
Naveen.
Anything that won't sell, I don't want to invent. Its sale is proof of utility, and utility is success.
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
thanks all of your your response, and sorry for not being able to correspond ...
The wild card option, as everyone tested doesnot work, I hope some derivations could be made or some parameter can be passed while running the master sequencer...
if you have any suggestions please let me know
thanks all of you
nsg
The wild card option, as everyone tested doesnot work, I hope some derivations could be made or some parameter can be passed while running the master sequencer...
if you have any suggestions please let me know
thanks all of you
nsg
-
- Participant
- Posts: 23
- Joined: Wed Jan 18, 2006 10:43 am
Hello Nsg,
Even i've come to the same point, where i've to wait for different files, and if file1 lands in the directory, my job activity 1 has to trigger,
if file2 lands, job activity2 has to trigger,
it's almost like ur query...
can u plz tell me how did u get your solution, if you found one,
what type of derivations or parameters did you use while running the master sequence.
Thank you so much...
and even if someone has some ideas...plz let me know,
thank you in advance
Usha...
Even i've come to the same point, where i've to wait for different files, and if file1 lands in the directory, my job activity 1 has to trigger,
if file2 lands, job activity2 has to trigger,
it's almost like ur query...
can u plz tell me how did u get your solution, if you found one,
what type of derivations or parameters did you use while running the master sequence.
Thank you so much...
and even if someone has some ideas...plz let me know,
thank you in advance
Usha...
Nsg wrote:thanks all of your your response, and sorry for not being able to correspond ...
The wild card option, as everyone tested doesnot work, I hope some derivations could be made or some parameter can be passed while running the master sequencer...
if you have any suggestions please let me know
thanks all of you
nsg
-
- Premium Member
- Posts: 1255
- Joined: Wed Feb 02, 2005 11:54 am
- Location: United States of America
Hi Usha,
Use the 'Wait-for-file Activity' before each of the 'Job Activity' that has to be triggerred when a file appears.
Thanks,
Naveen.
Use the 'Wait-for-file Activity' before each of the 'Job Activity' that has to be triggerred when a file appears.
Thanks,
Naveen.
Anything that won't sell, I don't want to invent. Its sale is proof of utility, and utility is success.
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
-
- Participant
- Posts: 23
- Joined: Wed Jan 18, 2006 10:43 am
*************************************************************
DataStage Repository interface
Record J\92\ROOT on file DS_JOBOBJECTS cannot be written
*************************************************************
This is the error i'm getting while compiling my job,
i've put wait for file stages in front of each job activity...
thank you...
DataStage Repository interface
Record J\92\ROOT on file DS_JOBOBJECTS cannot be written
*************************************************************
This is the error i'm getting while compiling my job,
i've put wait for file stages in front of each job activity...
thank you...
-
- Premium Member
- Posts: 1255
- Joined: Wed Feb 02, 2005 11:54 am
- Location: United States of America
hi Usha,
I just created a sample sequence with your case.
i.e., Having a 'Wait-for-File Activity' in front of the 'Job Activity'
And everything compiled well.
I'm not sure why you are not able to do the same. Is there any other information we are missing?
Thanks,
Naveen.
I just created a sample sequence with your case.
i.e., Having a 'Wait-for-File Activity' in front of the 'Job Activity'
And everything compiled well.
I'm not sure why you are not able to do the same. Is there any other information we are missing?
Thanks,
Naveen.
Anything that won't sell, I don't want to invent. Its sale is proof of utility, and utility is success.
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
-
- Participant
- Posts: 23
- Joined: Wed Jan 18, 2006 10:43 am
Hi Naveen,
thank you so much for your time,
but i've done the same way,
ive put a wait for file1 -> job activity1
wait for file2 -> job activity2
both job activities to a Sequencer1 -> mail notification....
but even for saving it,
i'm getting the following error:
Unable to return an attached job
what may be the cause of it, i've checkd the jobs i specified in the job activity, they're running fine...
plz tell me ur example sequence, and what all u've specified in the triggers.
thank you so much...
Usha...
thank you so much for your time,
but i've done the same way,
ive put a wait for file1 -> job activity1
wait for file2 -> job activity2
both job activities to a Sequencer1 -> mail notification....
but even for saving it,
i'm getting the following error:
Unable to return an attached job
what may be the cause of it, i've checkd the jobs i specified in the job activity, they're running fine...
![Sad :(](./images/smilies/icon_sad.gif)
plz tell me ur example sequence, and what all u've specified in the triggers.
thank you so much...
Usha...
try creating a simple sequencer job, just a couple of job activities linked with each other. and try to compile them.
from the error msg you are getting, it seems like your DS_JOBOBJECTS hash file is corrupted. try the test and let me know what happens.
from the error msg you are getting, it seems like your DS_JOBOBJECTS hash file is corrupted. try the test and let me know what happens.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
-
- Participant
- Posts: 23
- Joined: Wed Jan 18, 2006 10:43 am
-
- Participant
- Posts: 54607
- Joined: Wed Oct 23, 2002 10:52 pm
- Location: Sydney, Australia
- Contact:
If the file is placed on your server by an external scheduler, such as Ctrl-M or SeeBeyond, why not configure the same scheduler to start the DataStage job that has to process the file?
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
-
- Premium Member
- Posts: 1255
- Joined: Wed Feb 02, 2005 11:54 am
- Location: United States of America
That is a good point, Ray. We did the same at the last site. CNTRL-M was watching files to trigger subsequent processes.
Regards,
Naveen.
Regards,
Naveen.
Anything that won't sell, I don't want to invent. Its sale is proof of utility, and utility is success.
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE
Author: Thomas A. Edison 1847-1931, American Inventor, Entrepreneur, Founder of GE