Best Info About How To Check An Empty File In Jcl
Hi, you can do this by using cond parameter.
How to check an empty file in jcl. Here client gives 30 files i need to check for every file for empty or not and i. By using idcams utility we can check whether. Print infile (dd1) count (1) /*.
I tried to use the same jcl to print a sequential dataset and my job ran fine. To open a file that has never contained records (an empty file), use a form of the open statement. Based on that you can bypass your step no 3.
First_char = my_file.read(1) # get the first character. How to check an empty file in jcl. If it doesn't, i want to create an empty version of the same file.
Which we can make use to check whether a file is empty. The below piece of code will determine whether the input sequential data set is empty or not. I have many files which i am receiving from client everyday.
Introduce a idcam step to check the file, if it empty then idcam step will return 4. There may be scenarios where you wish to check if a file is empty or not. A program must open and read.
There is a pgm pgm1 which write to an output file out.file. Print file is empty # the first. //in dd dsn=ums.d44201.jcl(dummy), // disp=shr //toolin dd * * set rc = 12 if the 'in' data set is empty, or * set rc = 00 if the 'in' data set is not empty count from(in) empty /* // if.