¿ªÔÆÌåÓý

ctrl + shift + ? for shortcuts
© 2025 Groups.io

Re: Some questions about BSAM files on DOS/VS


 

Piotr Kolasinski wrote:

I know that my questions may be stupid but ..
There are no stupid questions if they are asked. It is only when you don't ask your question that it becomes stupid. ;-)


2. If I define DLBL and EXTENTs in JCL, but phase executing
in JOB STEP does not touch (open, write) the file, will any
extent(s) be allocated and an entry created in the VTOC?
No. If the file is never OPENED, it will never be created.

If it is OPENED however, then the VTOC entries *will* be created with however many EXTENTS you defined in your JCL. If you never write data, then the file will simply remain empty.


3. If I have 2 extents defined, and my program writes data
only for one extent (i.e. only writes a small amount of data,
i.e. only enough to need the first extent), will the second
extent be allocated?
Yes. When a file is created, it is created with however many extents are in your JCL. DOS/VS does not automatically create new extents for you or automatically delete unused extents for you either. You need to MANUALLY maintain all of that yourself in your JCL. DOS is very different than MVS. It does not have any automatic space management logic. YOU, the user, must manage your dasd space manually yourself.

--
"Fish" (David B. Trout)
Software Development Laboratories

mail: fish@...

Join [email protected] to automatically receive all group messages.