Routine activity failing in sequence
Posted: Wed Oct 23, 2013 3:27 am
Dear All,
I am using the below routine in job sequence using routine activity which is added after sequencer which will have links multiple jobs for failed notifications.when ever adding this rouine activity there is an executing command activity which is calling a datastage job is failing and totally sequence is failing.
Please suggest me where to use this routine activity in the sequence and why am i not able call the job with execute command activity stage.
I am using the below routine in job sequence using routine activity which is added after sequencer which will have links multiple jobs for failed notifications.when ever adding this rouine activity there is an executing command activity which is calling a datastage job is failing and totally sequence is failing.
Code: Select all
$INCLUDE DSINCLUDE JOBCONTROL.H
JobName = FIELD(Arg1,"|",1)
evtMessage1 = ""
hJob1 = DSAttachJob(JobName, DSJ.ERRNONE)
latestID = DSGetNewestLogId(hJob1,DSJ.LOGFATAL)
For eventID = latestID To 1 Step -1
eventDetail = DSGetLogEntry(hJob1,eventID)
evtMessage = FIELD(eventDetail,"\",4)
evtType = Field(eventDetail,"\",3)
If evtType = "3" Then
evtMessage1 = evtMessage:"|":evtMessage1
END
Next eventID
Ans = evtMessage1
Please suggest me where to use this routine activity in the sequence and why am i not able call the job with execute command activity stage.