When IDMS readies a database area, it places a physical lock on a page to disallow update access to that same page from any other job. This document contains instructions on how to how to locate and interpret the lock byte on the page.
Release: All supported releases.
In looking at a database page, the page number of the page is stored in the last four bytes of the page. The area lock byte setting is stored in the two bytes preceding the page number. The specific value contained in these two bytes will vary depending on where this specific page resides within the page range for the area; the mode in which the area is readied; and on the number of updates which have been performed on this page.
For the first page in the area, these two bytes are set to a value of X'0001' whenever IDMS needs to open the area in update mode; this is referred to as the "area-in-use" lock. If the area is not in use by the CV for update (varied offline or readied in retrieval), then this area-in-use lock is set to X'0000'. For all other pages in the area, these two bytes contain a page update count; i.e. this value is increased by 1 every time that page is updated. If the value eventually reaches X'FFFF', on the next update it is set back to x'0000'.
These bytes are part of the PAGE FOOTER of a database page, which is structured as follows:
| Line space | Page Update count | Line index 0 | count or Area-in-use-lock | Page number | ---------------------------------------------------------------- 8 bytes 2 bytes 2 bytes 4 bytes
Thus, the fifth byte before the last position on the page is part of a half word (two bytes) which is used for
To summarize, to find and interpret the area-in-use lock: