Focal Point Banner
Community Center Education Summit Technical Support User Groups
Let's Get Social!

Facebook Twitter LinkedIn YouTube
Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     IBATCH JCL return code
Go
New
Search
Notify
Tools
Reply
  
IBATCH JCL return code
 Login/Join
 
Silver Member
posted
I tried using the IBATCH JCL in the ...WFM.DATA MVS library that came with our WebFocus 715 installation. It worked successfully, but whenever the report fails due to an error, it continued to send a zero return code.

Is there a way to make WebFocus to override or populate the MVS RC system variable so I can force an abend when a report ended unsuccessfully?


Thanks,
Ronnel C
WebFocus 7.1.5
IBM ZOS 1.6
 
Posts: 44 | Location: Fort Wayne, IN | Registered: February 07, 2007Reply With QuoteReport This Post
Expert
posted Hide Post
-QUIT FOCUS 99


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1958 | Location: Centennial, CO | Registered: January 31, 2006Reply With QuoteReport This Post
Silver Member
posted Hide Post
Thanks for the reply.

The problem with the -QUIT FOCUS , it only works when a TABLE FILE or MODIFY fails. Things like syntax error, invalid data types, and other kinds of error stops the focexec immediately, so the -QUIT does not get executed.

What I am trying to do here is to force the JCL to abend so that the operator would get notified and our job scheduler (CA7) would not kick off any other job that the abended job normally would. This means any type of error.


Thanks,
Ronnel C
WebFocus 7.1.5
IBM ZOS 1.6
 
Posts: 44 | Location: Fort Wayne, IN | Registered: February 07, 2007Reply With QuoteReport This Post
Expert
posted Hide Post
Ronn,

If you have any of those errors, you can:

Branch on
-IF &FOCERRORNUM NE 0 GOTO NO_GOOD;
-IF &FOCERRORNUM
If creating a hold:
-IF &LINES EQ 0 GOTO NO_GOOD;

-NO_GOOD
-QUIT FOCUS 99

Tom


Tom Flynn
WebFOCUS 8.1.05 - PROD/QA
DB2 - AS400 - Mainframe
 
Posts: 1958 | Location: Centennial, CO | Registered: January 31, 2006Reply With QuoteReport This Post
Gold member
posted Hide Post
We normally include the FIN in the Focexec itself. f it fails halfway, the fin does not get executed, and FOCUS then returns a COND CODE of 8


Diptesh
WF 7.1.7 - AIX, MVS
 
Posts: 79 | Location: Warren, NJ, USA | Registered: October 25, 2006Reply With QuoteReport This Post
Platinum Member
posted Hide Post
We have a series of ABORT routines, designed for the COBOL programer. I call the one of them that allows setting a USER ABEND Code, with this DM.

-RUN
-SET &ABORT = IF &RECORDS NE 0 THEN 0 ELSE ABORT3(0333);

The sub-routine is in LINKPAC area so the MVS can find it without a special STEPLIB. You may have to ask someone who wastes time doing COBOL what the use to ABORT a program, and use that module instead of my ABORT3,


Jim Morrow
Web Focus 7.6.10 under Windows 2003
MVS 7.3.3



 
Posts: 129 | Registered: June 01, 2005Reply With QuoteReport This Post
Silver Member
posted Hide Post
Thanks again for all the replies.

I tried the -QUIT anyway and even the -QUIT FOCUS 12 but it did not affect the return code of the JCL. I also tried this with and without the FIN command in the JCL but it did not have any affect.

I haven't tried creating a subroutine to pupulate a variable, but eventually it will all boil down to modifying the RC mvs system variable which the -QUIT is not doing anyway.

Maybe I'll try executing a TSO command to run a JCL that calls a program that does not exist if I get a &RETCODE that is greater than 1.

I can also DYNAMIC ALLOCATE a file on a &RETCODE that is greater than 1. Then I can check for the existence of that file, and if it exists that means there was an error, then I will execute that non existent program to force an abend.

Keep the suggestions coming. I am open for any idea to work around this.

Thanks again for all the replies!


Thanks,
Ronnel C
WebFocus 7.1.5
IBM ZOS 1.6
 
Posts: 44 | Location: Fort Wayne, IN | Registered: February 07, 2007Reply With QuoteReport This Post
  Powered by Social Strata  
 

Focal Point    Focal Point Forums  Hop To Forum Categories  WebFOCUS/FOCUS Forum on Focal Point     IBATCH JCL return code

Copyright © 1996-2018 Information Builders, leaders in enterprise business intelligence.