11.01.2013 Views

ABCs of z/OS System Programming Volume 3 - IBM Redbooks

ABCs of z/OS System Programming Volume 3 - IBM Redbooks

ABCs of z/OS System Programming Volume 3 - IBM Redbooks

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

4.42 VSAM: Mapping a linear data set<br />

WINDOW<br />

(Address space)<br />

(Dataspace)<br />

or<br />

(Hiperspace)<br />

Figure 4-52 Mapping a linear data set<br />

LDS<br />

BLOCK3<br />

BLOCK4<br />

BLOCK5<br />

OFFSET<br />

SPAN<br />

Mapping a linear data set<br />

To establish a map from a linear data set to a window (a program-provided area in multiples <strong>of</strong><br />

4 KB on a 4 KB boundary), the program issues:<br />

► DIV IDENTIFY to introduce (allocate) a linear data set to data-in-virtual services.<br />

► DIV ACCESS to cause a VSAM open for the data set and indicate access mode<br />

(read/update).<br />

► GETMAIN to allocate a window in virtual storage where the LDS will be mapped totally or<br />

in pieces.<br />

► DIV MAP to enable the viewing <strong>of</strong> the data object by establishing an association between<br />

a program-provided area (window) and the data object. The area may be in an address<br />

space, data space, or hiperspace.<br />

No actual I/O is done until the program references the data in the window. The reference will<br />

result in a page fault which causes data-in-virtual services to read the data from the linear<br />

data set into the window.<br />

DIV SAVE can be used to write out changes to the data object. DIV RESET can be used to<br />

discard changes made in the window since the last SAVE operation.<br />

Chapter 4. Storage management s<strong>of</strong>tware 175

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!