Communicator 3000 MPE/iX Release 6.0 (Platform Software Release C.60.00) (30216-90269)

166 Chapter 10
Technical Articles
IMAGE/SQL with TurboIMAGE/XL Enhancements
Dynamic Detail Dataset Expansion (DDX) Fix
(SR# 5003-367607)
The DDX feature of TurboIMAGE/XL has a known problem which may
cause you to lose some of your new data entries added following the
dynamic detail dataset expansion. This defect has been in the feature
since its introduction, but has surfaced recently and has been reported
by a few customers. The problem has been fixed both for MPE/iX 5.5
and MPE/iX 6.0. The patch ID for MPE/iX 6.0 is TIXKX62 (or
superseded patch id) and the TurboIMAGE/XL version is C.07.10. This
patch is contained in this release.
Problem Description
The problem is that, following a dynamic expansion, the addition of the
new data entries (DBPUTs), which exceed the INCREMENT in number, are
written to the data set beyond the physical end-of-file (MPE EOF).
When the database is closed and reopened, those new entries exceeding
the INCREMENT are inaccessible. If a program attempts to read that
data or add more data entries in that area, it gets an error -212,
Database is Corrupt. The following diagram illustrates the
problem.
||
||
||
||
|----------|-----> Old MPE EOF as well as IMAGE EOF (e.g., 1)
||
|INCREMENT | New MPE EOF (e.g., 51) after expansion by
|----------|-----> INCREMENT equivalent to 50 MPE records.
| |-----> New entries placed from this point on are lost.
||
|----------|-----> New IMAGE EOF (e.g., 101) as calculated by the
adjustment to CAPACITY of set, following the
expansion.
The real problem is that, for certain expansions, the new CAPACITY is
inadvertently adjusted by adding the INCREMENT more than once
instead of adjusting only once. This results in incorrect calculation of
IMAGE EOF and subsequently allows new data entries to be placed in
the area which really does not belong to the data set file. Therefore,
when the data set is closed, the new entries added beyond the MPE
EOF are not retained as part of the data set file by the MPE file system
and are subsequently lost.
The circumstances in which such an erroneous adjustment could take
place are as follows:
While an actual DDX is being performed by DBPUT for one process, a
second process (user) accessing the same data set for the first time
causes execution of IMAGE's open data set module. In a narrow
timing window, the result will be incorrect extraneous adjustment of
the CAPACITY by adding the INCREMENT! Specifically, the CAPACITY
has been incremented twice, while the MPE EOF has been correctly
incremented—only once.