Exception handler

A forum for discussing DataStage<sup>®</sup> basics. If you're not sure where your question goes, start here.

Moderators: chulett, rschirm, roy

Post Reply
ravitell1
Participant
Posts: 12
Joined: Wed Aug 11, 2010 12:28 pm

Exception handler

Post by ravitell1 »

If any job aborts in sequencer, I need the job report in the mail why it has been aborted.. can i use the #Exception_Handler.$ErrMessage#..If so ..how can i capture the message..
help appreciated..

Thanks.
Ravi.
Pacific007
Participant
Posts: 35
Joined: Wed Oct 06, 2010 11:24 am

Re: Exception handler

Post by Pacific007 »

ravitell1 wrote:If any job aborts in sequencer, I need the job report in the mail why it has been aborted.. can i use the #Exception_Handler.$ErrMessage#..If so ..how can i capture the message..
help appreciated..

Thanks.
Ravi.
Hi Ravi,

Already you will get the error details in log file. If you want that to be emailed you have to use Standard After job Subroutine- DSJobReport

The routine takes an argument comprising two or three elements separated by semi-colons as follows:

Report type. 0, 1, or 2 to specify report detail. Type 0 produces a text string containing start/end time, time elapsed and status of job. Type 1 is as a basic report but also contains information about individual stages and links within the job. Type 2 produces a text string containing a full XML report.

Directory. Specifies the directory in which the report will be written.

XSL stylesheet. Optionally specifies an XSL style sheet to format an XML report.

If the job had an alias ID then the report is written to JobName_alias.txt or JobName_alias.xml, depending on report type. If the job does not have an alias, the report is written to JobName_YYYYMMDD_HHMMSS.txt or JobName_YYYYMMDD_HHMMSS.xml, depending on report type.


This report file you can email through email notification stage.
Pacific
Post Reply