Posted: Sun Jul 06, 2003 1:09 am Post subject: what's the use of vsam init?
hi all,
i know that i can use IDCAMS to allocate a vsam file.
but , before i can use it in my cobol program,
i have to initialize this file.
could anybody tell why?
what vsaminit do actually to the file?
Joined: 28 Nov 2002 Posts: 77 Topics: 7 Location: Chennai, India
Posted: Mon Jul 07, 2003 5:32 am Post subject:
Its all about HURBA.
From VSAM Demystified:
Quote:
3.9.1 High used RBA value (HURBA) for KSDS
There are two HURBAs per KSDS cluster: the data HURBA, and the index HURBA:
• Data HURBA
This is the RBA of the physically highest record in data CI (it does not
imply the highest key, because the existence of splits). In other words, it
points to the end of the last CA which ever, at any time, contained data. It
is incremented by one CA, if a CA split or add-to-the-end in a new CA
occurs. It is always on a CA boundary.
If all logical records are deleted the HURBA does not turn to zero — only
via create or re-setting. Also, if the data set was defined with the Reuse
option, in this case at Open time, HURBA is re-set to zero.
When share option cross-system 4 is set to the data set, this value cannot
be modified.
If a data set has HURBA=0, it cannot be opened for input.
• Index HURBA
This points to the end of the last index CI written. It is incremented by one
CI if a new record is added to the index. Separate HURBA values are
maintained for the imbedded sequence set, and the high level index if
IMBED is used. Index HURBA is always on a CI boundary.
HURBA is set to a non-zero value when you initialize the file, enabling you to open the file for input.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum