I have job where I am triggering JOB1 using UtilityRunJob Transform -1 stage then Trigger JOB2 in another Transform-2 stage. I want to trigger JOB2 only when Transformer-1 status is successful.
I tried using DSLinkLastErr = 0 and DSStageLastErr = 0 in both transformer stage, but could not achieve what i am want.
Am i doing right? Any thoughts/Info appriciated.
Here is job flow:-
SeqFile--------->Xfrm-1--------->Xfrm-2
| |
| |
V V
Job-1 Job-2
When a link is from one active stage Xfm1 to another active stage Xfm2 there will never be any error.
Therefore you need a different technique, probably an output constraint on Xfm1.
But do you really want to trigger Job1 and - possibly - Job2 for every row in the text file? This is what your job design suggests. Possibly there is a better solution involving a job sequence.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
Input Seq file contains only one record with 3 values separated by a delimeter, i need to get those values as a parameters to the next JOB-1 and JOB-2 , so right now i am reading those values in Xfm-1 , stage variable area and passing using pipe to job paramters by invoking UtilityRunJob from Xfm1 and JOB2 from Xfm2.
While i am doing testing i forced to abend JOB-1 (to test), but it is executing JOB-2. My requirement is, if JOB-1 successfull then only run JOB-2.
For that I can seperate them in to 2 different jobs, but can it be done in only JOB by forcing some constraints??
Or are there any other ways I can achieve this.
Basically i need to read a parameter seq file and use those values as a Job paramers.
If you execute Job1 from a stage variable in Xfm1, then you can use the return value (its exit status) to constrain the output from Xfm1 so that Xfm2 is only triggered if the value is 1 (finished OK) for example.
It's a cumbersome method, though, one that would be so much easier using a job sequence, where the trigger is directly fed by the job's exit status. Reading the file to get the three parameter values is also quite easy, with either an Execute Command activity (or three) or a Routine activity.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.