How to test thru JCL if any file(PS or VSAM) is empty or
not. I do not want to use any COBOL prog or Ezytrieve and
want to do using utility.
Answer Posted / deb
First SORT the input file.
Assume the sorted o/p is in MY.SORT.FILE, then run this step
//CHEKEMTY EXEC PGM=IDCAMS
//SYSPRINT DD SYSOUT=*
//MYFILE DD DSN=MY.SORT.FILE,DISP=SHR
//SYSIN DD *
PRINT INFILE(MYFILE) CHARACTER COUNT(1)
if the above step returns a RC=4, then the file is
empty
| Is This Answer Correct ? | 10 Yes | 5 No |
Post New Answer View All Answers
Define concatenating?
I have a cobol db2 program(PGM A) where other program (PGM B) will call this program and passes some 50 fields data to PGM A. PGM A has some layout in which it receives the data from PGM B. And this layout has been copied in the linkage section pf PGM A. After getting the data, PGM A writes the data in a flat file in the same layout which it receives from PGM B. PGM B is a simple COBOL pgm. Please provide a JCL to run these programs.
Does jcl support automatic restart?
Is it possible to define dd statements as you want?
Is condition checking possible in jcl?
How do you submit a job for execution?
What are hierarchy levels in jcl?
How gdg are concatenated?
if we want to use a gdg which is already created by some job, then how to use the reference of the last generation in a jcl?
what are the statements that are not valid to be included in an include statement?
what is the difference between JES3 and JES2?
What is one line to pass PARM from JCL to COBOL?
what is the use of JCL?
which utility is used a dummy utility?
what is use of space parameter in dd statement?