Page 1 of 3

TWS job scheduling

PostPosted: Thu Mar 06, 2014 12:06 pm
by ramu65
hi
I wanted to run an application every 10 minutes using OPC.After going through the forum,I found that an option is available for this in run cycle.I created a rule for the application to run only on first thursday of march and using the E command I specified the repeat interval ,from time and until time.But the application run just once at the start time and repeated occurrences did not happen. The application had a job to copy from contents from 1 gdg version to another

//sortin dd dsn=id.gdg.dataset(0),
// disp=shr
//sortout dd dsn=id.gdg.dataset(+1),
// disp=(new,catlg,delete)


1.can some one please help me resolve the problem????
2.Also,is there any possibility in tws to copy the error details(error code and stepname alone) into a dataset when a job fails and success message in case of successful execution.

Re: TWS job scheduling

PostPosted: Thu Mar 06, 2014 3:08 pm
by NicC
I split this from the other topic as I thought you were piggy-backing but I see apru was piggy-backing and so your original post was ignored. It did not help that you diod not come back with any response. It is always good to know that you are finished with a topic and why e.g. resolved by talking with co-worker or reading manual or whatever.

Re: TWS job scheduling

PostPosted: Thu Mar 06, 2014 3:22 pm
by apru
actually I found aprus queries useful since they were similar to mine :-)

Re: TWS job scheduling

PostPosted: Thu Mar 06, 2014 5:33 pm
by NicC
apru wrote:actually I found aprus queries useful since they were similar to mine :-)

Now this is confusing - apru found his own queries were similar to his (aprus's) queries!
Whatever - you do NOT tailgate other peoples queries.

Re: TWS job scheduling

PostPosted: Thu Mar 06, 2014 6:03 pm
by enrico-sorichetti
broken caching algorithm, I suppose ... :mrgreen:

Re: TWS job scheduling

PostPosted: Thu Mar 06, 2014 7:55 pm
by Blackthorn
This is an odd one. The EVERY command is pretty straightforward, I can't really think of anything that you could have done that might cause the problem.

The only thing that seems a little odd is that you have only set it to run on the first Thursday in March, which is today. Assuming the current plan is already built for today, new schedules will not be added that have an input arrival time prior to the existing current plan end time. What happens if you set it to run every day?

Re: TWS job scheduling

PostPosted: Fri Mar 07, 2014 10:11 am
by ramu65
Actually it is running for the first time and after that the application is ending in error.The error code is JCLI.

Re: TWS job scheduling

PostPosted: Fri Mar 07, 2014 11:34 am
by ramu65
Is there any possibility to copy the return code of an application(completed/ended in error) and the error info(return code and step name in case of a job ended in error) to a dataset after completion of an application????

Re: TWS job scheduling

PostPosted: Fri Mar 07, 2014 5:07 pm
by Blackthorn
ramu65 wrote:Actually it is running for the first time and after that the application is ending in error.The error code is JCLI.


Well, obviously the JCLI error is nothing to do with the scheduling of the job. Although it may be the case that if one run of the job is dependent on the previous run then no more will run once the first has failed. Are they all in the current plan?

Re: TWS job scheduling

PostPosted: Fri Mar 07, 2014 5:10 pm
by Blackthorn
ramu65 wrote:Is there any possibility to copy the return code of an application(completed/ended in error) and the error info(return code and step name in case of a job ended in error) to a dataset after completion of an application????


Not easily, no. You would have to write batch job to run and do it. The scheduling of this would be tricky though if you want it to run when the application has completed and if a job is in error. You'd have to have one version of the job that runs when the application is complete and another that runs in the event of any errors.

Why do you think you want this? There may be another way to achieve your goal.