Thomas David Rivers wrote:
I've been wading thru the documentation (DFSMS Using Data Sets), etc...
trying to figure out why the DCBBLKSI field of my DCB is not
being filled in for a RECFM=U data set for INPUT. (Non-LBI)
In particular, I want to allocate a buffer of sufficient size to hold
any block
we might read for a pre-existing RECFM=U data set.
To answer some of the questions:
- The OPEN is successful.
- This is an OPEN for READ.
- After the OPEN has finished, the DCBBLKSI field remains 0.
- In this case, we _could_ use 32760 for the size of the read buffer
to allocate.. that seems rather large... and, does LBI mean that
the buffer should be larger? (I couldn't find anything about the
maximum block size for an LBI file, but I didn't (yet) look that hard
either.) And, what about SPANNED? Does that come into play?
- This is what ISPF says about the data set, so the VTOC does have
a BLKSIZE:
General Data Current Allocation
Volume serial . . . : DAVE Allocated blocks . : 2,035
Device type . . . . : 3390 Allocated extents . : 1
Organization . . . : PO Maximum dir. blocks : 10
Record format . . . : U
Record length . . . : 0
Block size . . . . : 10240 Current Utilization
1st extent blocks . : 2035 Used blocks . . . . : 2
Secondary blocks . : 500 Used extents . . . : 1
Used dir. blocks . : 1
Number of members . : 1
Dates
Creation date . . . : 2014/07/17
Referenced date . . : 2014/07/17
Expiration date . . : ***None***
So - I suppose my question boils down to "If you don't a-priori know
the BLKSIZE
of a RECFM=U data set, how do you know how large of an input buffer
to allocate?". If the user didn't specify a BLKSIZE in the JCL (or SVC
99 allocation)
and the program doesn't want to specify a BLKSIZE (so it can best use
memory),
what do you do? How do you allocate enough memory for any possible READ?
Again, this is for INPUT... the file will eventually be READ...
- Dave Rivers -
--
[email protected] Work: (919) 676-0847
Get your mainframe programming tools at http://www.dignus.com
----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN