Is there a way to check for an empty file in JCL other than
using IEBCOMPR and the command PRINT COUNT(1)?
Answer Posted / arul anand.a
//STEP01 EXEC PGM=IDCAMS
//SYSUDUMP DD SYSOUT=*
//SYSOUT DD SYSOUT=*
//SYSPRINT DD SYSOUT=*
//INDD DD DSN=FILE1,
// DISP=SHR
//OUTDD DD DSN=FILE2,
// DISP=SHR,
REPRO INFILE(INDD) OUTFILE(OUTDD) COUNT(1)
THIS WILL GIVE RC = 04 IF THE INFILE IS EMPTY.
OTHERWISE IT WILL GIVE 0.
| Is This Answer Correct ? | 10 Yes | 1 No |
Post New Answer View All Answers
Why include statement is used in a jcl?
A dd statement consists of 4 fields. Name them?
How can values be passed from the job stream to an executable program?
what are JCLLIB and STEPLIB in JCL?
what operation is performed by job statement?
Can an individual step be restricted from using all the jobs allowed cpu time?
what is the use of IEBGENER utility?
What do you understand by the term job time – out and how can you overcome that?
what is “Cond= even” and “Cond=only”?
When output dataset space is required, what quantity categories are used?
which utility is used a dummy utility?
List in order the hierarchical levels of jcl?
In job processing, what happens in conversion stage?
How jcl is used for testing batch programs?
What is the difference between the positional and keyword parameters? Give examples.