Sequencer fails.

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
DeepakCorning
Premium Member
Premium Member
Posts: 503
Joined: Wed Jun 29, 2005 8:14 am

Sequencer fails.

Post by DeepakCorning »

I have a very simple sequencer which calls a routine and then passes the number generated by the routine to the server job. The number generated from the routine is just a counter and does not have a complex logic. But whenever i try to run this its giving me a error -->


..JobControl (@GetNextBatchNumber): Controller problem: Unhandled failure (4) encountered calling routine DSU.GetNextBatchNumber


Each time I run the job the Unhandled failure (4) number increases by one. Also if i try to run the routine manually i am able to get correct result.
Any suggestions?
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

A Sequencer cannot fail. An "any" sequencer fires its output(s) when any of its inputs has fired; an "all" sequencer fires its output(s) when all of its inputs have fired.

Your problem seems to be with a job sequence detecting a failure in one of your rouines (GetNextBatchNumber). I presume you are calling this with a Routine activity, but the trigger from the activity requires that it return 0 (for success). Change the trigger so that it does not handle non-zero return value as a failure code. Search the forum for examples.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
DeepakCorning
Premium Member
Premium Member
Posts: 503
Joined: Wed Jun 29, 2005 8:14 am

Post by DeepakCorning »

I guess I misguided you by saying Sequencer. I was talkign about Sequencer Job and not the stage. the sequencer Job has only two stages - The routine activity and the job call.
I_Server_Whale
Premium Member
Premium Member
Posts: 1255
Joined: Wed Feb 02, 2005 11:54 am
Location: United States of America

Post by I_Server_Whale »

Hi Deepak,

It is called a "Sequence" job and never a "sequencer" job.

That is what Ray has been trying to convey to you and all others from a long period of time.

Many 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
rasi
Participant
Posts: 464
Joined: Fri Oct 25, 2002 1:33 am
Location: Australia, Sydney

Post by rasi »

Try create a additional link from the Routine Activity with Failed(Conditional) Trigger and pass this dummy link to a Sequence Condition All. The project now I am working on had the same problem before and it is now a standard to have this dummy link created whenever we use routine activity. For some reason when a routine fails to execute then it does expects this dummy link to handle failure on routine activity.
Regards
Siva

Listening to the Learned

"The most precious wealth is the wealth acquired by the ear Indeed, of all wealth that wealth is the crown." - Thirukural By Thiruvalluvar
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Better to use an 'Otherwise' trigger... and make sure you set the Sequencer to Any not All. :wink:

The reason why this is needed is well documented in the help available either online or in the pdf documents on your client pc.
-craig

"You can never have too many knives" -- Logan Nine Fingers
anujgarg
Participant
Posts: 38
Joined: Sun Jun 26, 2005 11:17 pm

Re: Sequencer fails.

Post by anujgarg »

Hi Deepak,

First , you have to handle failure of routine also in sequencer and another thing may be that you are returning the number through routine.while you are using the routine in sequencer.it is like before/after stage routine so in that case your answer for routine must be 1 or -1 or 0.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Change the trigger so that it does not handle non-zero return value as a failure code. Search the forum for examples.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
bgs_vb
Premium Member
Premium Member
Posts: 79
Joined: Mon Jan 02, 2006 5:51 am

Post by bgs_vb »

Hi Deepak,

Is this one related to loading of PS data to PS EPM db?

Vindy
Post Reply