DSJob -logsum

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
hassers
Participant
Posts: 14
Joined: Thu Dec 11, 2003 11:34 am
Location: Chester, UK

DSJob -logsum

Post by hassers »

DS v7, Server UNIX AIX

Have created a UNIX script that :
- picks up parameters,
- initiates DSJOB RESET (if required)
- runs the DSJOB

The issue is at the back-end picking up results of the Job

Using a DSJOB - LOGSUM
- this picks-up WARNINGS and FATALS

Problem is that this returns WARNINGS / FATALS for all runs of the JOB, when we want only the results of the last run.

Is there a way to retrieve log entries for the last run only?

Alternative is to ensure the Log file is empty before run, but this isn't ideal.
- Does anyone know how to reset a JOB LOG via a UNIX script?


Thanks to anyone who can help :?:
Steve
Thanks

Steve
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

Not sure if this helps or not, but I've done the same thing from Job Control...

You can use DSGetJobInfo with DSJ.JOBSTARTTIMESTAMP to get the time the current run of the job started. Then, a call to DSGetLogSummary can take a start time parameter to constrain the output to only messages from the current run. You can then loop thru the output to find what you need.

Don't think this is accomplishable from the command line. :? You could always try setting your job's auto purge option to purge everything other than the current run when finished. Or call a followup job to get the information for you...
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply