Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Hi all, My COBOL program's output

Status
Not open for further replies.

deveshjogal

Programmer
Dec 30, 2002
61
Hi all,
My COBOL program's output file is a variable length file.
In the DD statement of JCL which of the following will be the best option

RECFM=V OR
RECFM=VB

What is the differnce between these two ??

Devesh
 
RECFM=V is for variable length records, 1 record per block. RECFM=VB is for variable length records, blocked as much as possible while still fitting the block into the BLKSIZE specified.

I generally go for VB and use a BLKSIZE that approaches 1/2 a track of the DASD you're using (assuming real CKD devices). That's generally a number around 22,000. With the newer DASD that emulate CKD devices, I'm not sure what the best BLKSIZE would be. I'd check with my system programmer for advice specific to your installation.

Note that a single record cannot exceed BLKSIZE unless you specify spanned records (RECFM=VBS).

Good luck.

Glenn
 

I normally let the system determine the record format from the Program specification in the FD definition:

Recording Mode F (Fixed)
Recording Mode V (Variable)

Or if you need to specify in the JCL:

DCB=(RECFM=VB,BLKSIZE=0)

The Blocksize of 0 will allow the system to detemine the optimal bloking factor depending on the specifications of the drive that it picks.

Specifing the Blocksize has led to some wasted space on our site when upgrades were done to the disk packs.
 
Hi Dev,

In addition to what has been said it's also a good idea to choose the AWO compiler option when using VB recs. Look it up in your manual.

Regards, Jack.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top