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 / manid
//STEP1 EXEC PGM=IDCAMS
//DD1 DD DSN=FILE1
//SYSPRINT DD SYSOUT=*
//SYSIN DD *
PRINT INFILE(DD1) COUNT(*)
/*
IF STEP1 RETURNS RC=4 THEN FILE1 IS EMPTY FILE
I HOPE THIS WILL HELP YOU
Thanks
ManiD
Is This Answer Correct ? | 3 Yes | 4 No |
Post New Answer View All Answers
how can you check if a file is empty using jcl?
What is the function of //cntl statement?
I have many files which i am receiving from client everyday. I have one step for every file to check for empty or not. Here client gives 30 files i need to check for every file for empty or not and i need to perform 30 steps. Can I do it in single step. Dynamically i need to change the File name in my step.
Which statement is used to identify the private libraries in job?
Explain the purpose of dd dummy statement?
In sms datasets, what is the function of the dd avgrec keyword?
what operation is performed by job statement?
What is the job entry system used in your project? based on what criteria the sequence of jobs are picked if priority is not mentioned in the job card?
what is the compile process of cobol program expalin with code
Matching Logic in Jcl not in cobol.Could any one please answer this question
how can a gdg base be created in a jcl. What is the difference between empty and scratch parameter while defining/altering gdg base?
what is a jcl?
Differentiate between addressing mode and run mode.
What statement marks the beginning of an in-stream or cataloged procedure in jcl and assigns default values to parameters defined in the procedure?
Suppose I have a program in cobol name ”careerride” and want to execute the program by jcl. Specify the process?