CA View - SARBCH /LIST has Non-Zero Return Code
search cancel

CA View - SARBCH /LIST has Non-Zero Return Code

book

Article ID: 206376

calendar_today

Updated On:

Products

View

Issue/Introduction

When using the ISPF interface, you can wildcard a Sysout ID name (with "*") and receive matches. 

When running SARBCH /LIST, you receive a non-zero condition code when trying to use the same criteria.

What is happening here?

Environment

Release : 14.0

Component : CA View

Resolution

Though the View online functions (including ISPF) will allow for the wildcarding of a Sysout ID or Report ID on the Primary panel, as well as in the filtering on the Sysout Selection List columns, the SARBCH utility does not.

The SARBCH utility /LIST function will list an individual sysout, a complete generation of archived sysout, or all archived sysout.

In a utility, to generate a listing of reports where you can obtain a list with part of a Sysout ID, that can be accomplished with use of the SARGRW utility, which is available in View starting with release 12.2.

The member CVDEJCL(SARGRW01) SARGRW program, which shows a list of reports with fields similar to what is shown in the SARBCH /LIST function, can be modified to select reports based on a Sysout ID substring, by substituting:

"/SELECT ARCHDATE = -0"
with
"/SELECT SUBSTR(ID,1,nn) = 'xxxxxxxxx'.

For instance, to generate a list of reports that start with ABC*, used would be:

"/SELECT SUBSTR(ID,1,3) = 'ABC'".

------------------------------------------------------------------------------------------------------------------------------------------------

SARGRW, being a programming language, does not function the same as SARBCH in that SARBCH is a utility.

The utility will provide messages if there is no requested output, the same as a panel would provide a message if a requested report was not in the database.

In a user-written program, the program can execute successfully (with a zero condition code), yet yield no output.

Non-zero condition codes in SARGRW would occur if there are statements with invalid code.

The output of SARGRW needs to be reviewed to see what results the coding yielded.