z/OS DFSMS Using Data Sets
Previous topic | Next topic | Contents | Contact z/OS | Library | PDF


Reblocking PDSE Records

z/OS DFSMS Using Data Sets
SC23-6855-00

PDSE members are reblockable. When reading the PDSE members, the system constructs the block size specified in the DCB. If the block size is not specified in the DCB, the default block size is used. The system packs as many records as can fit into the specified block size. Logical records are written to DASD in blocks whose lengths are not determined by the user, and can span physical records. The user-defined or system-defined block size is saved in the data set label when the records are written, and becomes the default block size for input. These constructed blocks are called simulated blocks.

Figure 1 shows an example of how the records are reblocked when the PDSE member is read:

Figure 1. Example of How PDSE Records Are Reblocked

Suppose you create a PDSE member that has a logical record length of 80 bytes, such that you write five blocks with a block size of 160 (blocking factor of 2) and five short blocks with a block size of 80. When you read back the PDSE member, the logical records are reblocked into seven 160-byte simulated blocks and one short block. Note that short block boundaries are not saved on output.

You also can change the block size of records when reading the data set. Figure 2 shows how the records are reblocked when read:

Figure 2. Example of Reblocking When the Block Size Has Been Changed

Suppose you write three blocks with block size of 320, and the logical record length is 80 bytes. Then if you read this member with a block size of 400 (blocking factor of 5), the logical records are reblocked into two 400-byte simulated blocks and one 160-byte simulated block.

If the data set was a PDS, you would not be able to change the block size when reading the records.

Go to the previous page Go to the next page




Copyright IBM Corporation 1990, 2014