Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Variable Block file

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
rajesh_mbt

New User


Joined: 27 Mar 2006
Posts: 95
Location: India

PostPosted: Wed Nov 26, 2008 3:22 pm    Post subject: Variable Block file
Reply with quote

Can any one clarify why we need to add 4 bytes with actual length for variable block file during submission of jcl?
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10232
Location: italy

PostPosted: Wed Nov 26, 2008 3:25 pm    Post subject: Reply to: Variable Block file
Reply with quote

how else would tell the block and record lengths
he VB layout is...
four bytes for the BDW bock descripotor word
followed by N tuples of
four bytes for the RDW record description word
the data itself

but anyway the practical reason is ... the manual says so
Back to top
View user's profile Send private message
Garry Carroll

Active Member


Joined: 08 May 2006
Posts: 992
Location: Dublin, Ireland / Edinburgh, Scotland

PostPosted: Wed Nov 26, 2008 3:27 pm    Post subject:
Reply with quote

The 4bytes contain the RDW (record descriptor word) which contains each individual record's length. Similarly, an additional 4 bytes are used to contain the size of the block containing the variable records.

Garry.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Thu Nov 27, 2008 12:06 am    Post subject:
Reply with quote

Hi,

A variable-length logical record consists of a 4-byte record descriptor word (RDW) followed by the data. The first 2 bytes contain the length of the logical record. The last 2 bytes must be 0 because these are used for spanned records. When using variable-length records on output, you must provide the RDW; for input, the operating system provides the RDW.

Click here, this link would give you a pictorial representation of what goes behind.
Back to top
View user's profile Send private message
Aaru

Senior Member


Joined: 03 Jul 2007
Posts: 1288
Location: Chennai, India

PostPosted: Thu Nov 27, 2008 4:59 pm    Post subject: Reply to: Variable Block file
Reply with quote

Quote:
The first 2 bytes contain the length of the logical record. The last 2 bytes must be 0 because these are used for spanned records.


Adding to what Anuj had posted, last 2 bytes are populated with hexadecimal Zeroes.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Changing of LRECL of a file abdulrafi DFSORT/ICETOOL 2 Fri Mar 24, 2017 3:25 pm
No new posts splitting a file abdulrafi DFSORT/ICETOOL 4 Fri Mar 24, 2017 11:51 am
No new posts Receive a file using PCOMM macro Harald.v.K IBM Tools 0 Thu Mar 23, 2017 6:50 pm
No new posts Export flat file data into excel sheet murali.andaluri DFSORT/ICETOOL 2 Mon Mar 20, 2017 5:39 pm
No new posts Formatting VB File Learncoholic DFSORT/ICETOOL 3 Mon Mar 20, 2017 12:29 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us