View previous topic :: View next topic
|
Author |
Message |
AJAYREDDY
New User
Joined: 17 Feb 2007 Posts: 52 Location: USA
|
|
|
|
Is there any IBM tool (similar to IEBGENER ICETOOL) to abend the Job based on condition code parameter?
Right now I am giving like this. The program AA0000CP is cobol program. It will run only when return code of previous step AC000111 is not equal to zeros. Then the Job will abend (beause this program has only abend routine in Procedure division). But instead, if there is any IBM tool that would be more helpful.
//AA0000CP EXEC PGM=AA0000CP,COND=(0,GE,AC000111)
If there is no tool can we write a abend step using ICETOOL ? |
|
Back to top |
|
|
Akatsukami
Global Moderator
Joined: 03 Oct 2009 Posts: 1788 Location: Bloomington, IL
|
|
|
|
Assuming that your shop doesn't not already have a program to produce an abend at will -- most have had such for decades -- you can write a trivial one in the language of your choice that calls CEE3ABD or CEE3AB2. |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
I believe there is a Utility from the old System/365 days. It is called IEBNPH.
Code: |
//PICKLE EXEC PGM=IEBNPH,COND=blah stuff |
It needs no DD statements, not even SYSOUT or SYSIN, STEPLIB or JOBLIB, but you can code them if you want. It has a reputation for being even shorter in code volume than IEFBR14, but if you locate it and browse it, you'll be able to confirm or deny that.
Works for me. Gets S806 every time. Remarkable how it has survived unchanged through so many versions of the Operating System. |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10872 Location: italy
|
|
|
|
using a non existing program to abend a job has been common practice since ,
let me think.... about 1975
the standard name was EXPCT806 ( expect an s806 )
and it was used mostly when OPC was pretty primitive and needed an aben for proper resource cleanup
nowadays it is a pretty outdated technique |
|
Back to top |
|
|
Nic Clouston
Global Moderator
Joined: 10 May 2007 Posts: 2455 Location: Hampshire, UK
|
|
|
|
I use PGM=NOTFOUND
For trying out JCL condition codes I have a little program that takes a parameter that is the return code required or even a parameter that will cause the program to abend. |
|
Back to top |
|
|
AJAYREDDY
New User
Joined: 17 Feb 2007 Posts: 52 Location: USA
|
|
|
|
Thank you all for inputs. I think right now I will go with my usual cobol program AA0000CP which calls CEE3ABD. This program has only this Call in procedure division with no other statements (except DISPLAY statements). |
|
Back to top |
|
|
|