Page 5 of 5

Re: Controlling proc RC

PostPosted: Mon Mar 28, 2011 11:21 pm
by Tim
My goal is not to prevent my job from returning 166 (or anything else but 0). Sometimes ftp really is broken (remote machine down, network down, whatever), and an alert really does need to be generated. I just don't want my job completion code to be 166 regardless of whether the ftp retry worked or not. Unfortunately, in JCL, that's just the way it is. And there's nothing that's "behaving badly". Ftp will fail for a variety of valid reasons, and appropriately report the result. One of those reasons is a transient network problem, and a simple retry will succeed. Currently, that process is handled manually by the operator; there's nothing to "make easier", except to automate the process, which JCL seems designed to prevent. As I explained previously, rewriting everything in glorbrik is not an option.

However, it MIGHT be possible to get the automated alert system to ignore a particular completion code, as it currently ignores 0 (and actually, I'm told, any code 4 or less). If that's the case, then all I have to do is set a step return code to a value higher than 166 that the alert system will ignore. Here's what I've got (plagiarized from http://en.wikipedia.org/wiki/IEFBR14):

JRC4000 START
USING JRC4000,15
B GO
DC AL1(L'ID)
ID DC C'JRC4000'
DS 0H
GO L R15,=x'FA0'
BR 14
END JRC4000