Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

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


Please Help Members By Posting Answers For Below Questions

what is use of dcb parameter in dd statement?

1343


What is concatenating?

1139


How to compare two files in SYNCSORT and on the mismatch record should be deleted from second file.

5597


Describe the various parameters utilized in the creation of a gdg?

1209


Is their any set of rules for dd? Explain.

1266


how you will the direct the data to spool using sysout option?

2473


What is the difference between the positional and keyword parameters? Give examples.

1317


What is the purpose of the dd keylen parameter?

1282


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.

1278


What are the utility programs in jcl?

1213


Suppose I have a program in cobol name ”careerride” and want to execute the program by jcl. Specify the process?

1173


What is the function of the dd mgmtclas keyword in sms datasets?

1294


what operation is performed by job statement?

1172


define cond parameter in jcl?

1326


List the various advantages of using jcl language?

1518