Rejects and Warning

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
ecclesr
Premium Member
Premium Member
Posts: 260
Joined: Sat Apr 05, 2003 7:12 pm
Location: Australia

Rejects and Warning

Post by ecclesr »

Hi

Just a query

We have recently upgraded from 7.0.0.39 to 7.5.1A. We believe that with the 7.0.0.39 when a Reject Row was set to Yes on a link that a warning event would be created along with a Reject event which could be detected by the job control warning limit test for a job ie ErrCode = DSSetJobLimit(hJob5, DSJ.LIMITWARN, 1)

We have found with 7.5.1A just checking the Reject Row will only produce a Reject event

Now also need to set Abort After Rows to that set for the warning limit.

It would be handy to have a limit type "DSJ.LIMITREJECT" so a test could set in the job control

Thanking you in advance
kcbland
Participant
Posts: 5208
Joined: Wed Jan 15, 2003 8:56 am
Location: Lutz, FL
Contact:

Post by kcbland »

Yeah sucks, don't it? You have 2 mechanisms for aborting a job once a link reaches a certain row count:

1. Hard-code the abort after rows limit in the constraint of a transformer stage output link
2. Use a polling type job control that periodically uses the API call for getting a links row count during the jobs run and then issue the API call for stopping a job once it exceeds your desired row limit.
Kenneth Bland

Rank: Sempai
Belt: First degree black
Fight name: Captain Hook
Signature knockout: right upper cut followed by left hook
Signature submission: Crucifix combined with leg triangle
rleishman
Premium Member
Premium Member
Posts: 252
Joined: Mon Sep 19, 2005 10:28 pm
Location: Melbourne, Australia
Contact:

Post by rleishman »

ecclesr wrote:We have found with 7.5.1A just checking the Reject Row will only produce a Reject event
I haven't experienced this problem with 7.5.1A. All of our jobs that process files to tables perform validation in a transformer and send failures down a link with the Reject condition checked and no constraint.

I'm pretty sure we don't get a Warning event though. My server is down at the moment so I cannot check. I think the job just completes with Finished (see log) status, which we propagate back to the calling Sequence as a Warning.

The job logs only ever show a Reject event when rows go down that link.
Ross Leishman
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

rleishman wrote:I'm pretty sure we don't get a Warning event though. My server is down at the moment so I cannot check. I think the job just completes with Finished (see log) status, which we propagate back to the calling Sequence as a Warning.
A status of 'Finished (see log)' means there are warnings in the job log - just not enough of them to abort the job. :wink: And the exit status of the job is a 2 instead of the 1 it reports when there are no warnings.

A link with the Reject Row option enabled has always 'just' dropped a warning into the job log recording the number of 'rejected' records on that link, I'd be surprised if they changed this in 7.5.1A. I'm assuming this is the 'Reject event' that the OP mentions. I'm not following what the issue is - are you saying that in 7.5.1A, if I set the 'Abort after x warnings' to 1 that the warning that the reject row writes into the log doesn't count against that limit and the job is not aborted? :?
-craig

"You can never have too many knives" -- Logan Nine Fingers
rleishman
Premium Member
Premium Member
Posts: 252
Joined: Mon Sep 19, 2005 10:28 pm
Location: Melbourne, Australia
Contact:

Post by rleishman »

Craig,

By "Reject Event", I mean the type of log message in Director. My jobs that have rows going down the reject link raise a single 'Reject' message in the log, but no 'Warning' messages.

I don't use the "abort after" option, so cannot say whether this affects results.
Ross Leishman
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

And all I'm trying to say is - unless something has changed - that "Reject Event" *is* a warning - marked yellow and causing your jobs to finish with a Finished (see log) status.

Dat's all. :wink:

Still curious about the other potential issue...
-craig

"You can never have too many knives" -- Logan Nine Fingers
ecclesr
Premium Member
Premium Member
Posts: 260
Joined: Sat Apr 05, 2003 7:12 pm
Location: Australia

Post by ecclesr »

Thank you all for your feedback

Example is we have a test job that only has the Reject Row check box set on the link. The job runs to finish creating a Reject event type in the log but no warning and so not detected by the warning limit test

There appears now to be requirement to also add the same value as the warning limit in the Reject links Abort After Rows column if it is required that the job is to stop after x warnings or x rejects

It just seems to be a double up and could easily be missed ie the developer sets the job control to have the warning limit set to x but the developer forgets to add the same value to the reject link Abort After Rows column

This is not a major just surprised
Post Reply