Job Sequence 's log

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
benny.lbs
Participant
Posts: 125
Joined: Wed Feb 23, 2005 3:46 am

Job Sequence 's log

Post by benny.lbs »

I have written a routine to get the latest DS job log using DSJ.JOBSTARTTIMESTAMP and DSJ.JOBLASTTIMESTAMP to decide the time range, and then use DSGetLogSummary to retrieve the detail job log.

Now I can get the latest DS job log by running this routine in after job routine.

What I want to do is to retrieve sequence's log. But after job routine doesn't exist in sequence, so it can not get the DSJ.JOBSTARTTIMESTAMP and DSJ.JOBLASTTIMESTAMP information.

Would you please give me a hand, thanks a lot.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

You can add a Routine Activity and modify your routine slightly (copy it to a transform function) so it's callable by that means. Make the Routine Activity the last activity in the 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.
benny.lbs
Participant
Posts: 125
Joined: Wed Feb 23, 2005 3:46 am

Post by benny.lbs »

ray.wurlod, I have already tried your suggestion before. But if I add a Routine Activity in the sequence, that means when this activity running the sequence is running too, so how to get its DSJ.JOBLASTTIMESTAMP ?

ray.wurlod wrote:You can add a Routine Activity and modify your routine slightly (copy it to a transform function) so it's callable by that means. Make the Routine Activity the last activity in the Sequence.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

You're right, you can't. But, if you're in the routine activity that is the final piece of the sequence, the time "now" should be close enough.

Code: Select all

Oconv(Date(),"D-YMD[4,2,2]") : " " : Oconv(Time(), "MTS:")
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
benny.lbs
Participant
Posts: 125
Joined: Wed Feb 23, 2005 3:46 am

Post by benny.lbs »

That 's a good idea, thanks a lot
ray.wurlod wrote:You're right, you can't. But, if you're in the routine activity that is the final piece of the sequence, the time "now" should be close enough.

Code: Select all

Oconv(Date(),"D-YMD[4,2,2]") : " " : Oconv(Time(), "MTS:")
Post Reply