Page 1 of 1

DSJobReport for a Job Sequence

Posted: Tue Feb 28, 2006 5:11 pm
by rleishman
Two things to enable one feature:

1. An After-Job-Subroutine equivalent for Job Sequences. Key feature - it runs no-matter-what when a Job Sequence finishes.

2. DSGetJobInfo(SeqHandle, DSJ.JOBINTERIMSTATUS) must return meaningful values for Job Sequences, rather than 99 (No Running).

These two things will allow the use of DSJobReport for a Job Sequence, and simplify the statistics gathering process.

Posted: Tue Feb 28, 2006 7:23 pm
by kduke
EtlStats can be run if the sequence fails or is successful. You need to have an exception handler run the main job. Otherwise run this job as the last job of the sequence.

It translates 99 into the correct description. It will get row counts for all jobs, one job, all jobs in a sequence or all jobs in a category. It will store the results in your warehouse tables so you can report on them. It will email these reports at the end of a sequence as attachments.

It can also retreive row counts from log files. It can also be used to automate a QA process of DW tables.

It is also free on my tips page.

I added some new features to it today which are pretty cool. I will post them in a few days. It takes a few minutes to gather row counts for the sequence that is almost done. I took the job DSJobReportDbDriver and saved it as DSJobReportDbDriverNoWait. All this job does is run DSJobReportDbDriver without WaitForJob step. This runs DSJobReportDbDriver in the background and your sequence finishes. If you change the hard coded values for InvocationId to DSJobName then you can copy this stage to other sequences and not change anything. Makes it a lot easier to implement. I think I will integrate Peter's ini file concept as well and his blat.exe email attachment logic. You will like this stuff.