Overview of the Reorg function
With the Reorg function, the input (disorganized) database and the output (reorganized) database use different data sets.
A segment is unloaded by the Unload function and is passed directly to the Reload function for reload unless you specify the OLDDBD keyword. For more information, see OLDDBD.
The index maintenance records, if any, are passed to the Index Build function. This process continues for each segment. The Index Build function sorts the index records and creates the index databases. You can take an image copy of the database as it is reorganized.
The Reorg function automatically invokes the prefix resolution and update function if the database has logical relationships. (For limitations, see Reorg-function.)
The term standard reorganization refers to a reorganization where you use the database, rather than an HD Unload file, as input. To execute a standard Reorg function reorganization, specify INPUT(DB) or accept it as the default.
Figure 1 shows the system flow for the Reorg function.
Figure 1. Reorg function system flow
Figure 2 shows the input and output processes of a standard Reorg function reorganization.
Figure 2. Inputs and outputs of standard Reorg function reorganization
Table 1 lists the names that are recognized by the Reorg function in a standard reorganization. It shows the relationship between input names (from the disorganized database) and output names (for the reorganized database).
Table 1. ddnames and data set names
Names | Input (to the Unload function) | Output (from the Reload function) |
---|---|---|
ddnames | ddnames defined with the UNLDD or UNLDDLST keywords or dynamically allocated | DBD ddnames |
Data set names | Disorganized primary index and database data set names (the names registered to DBRC) No secondary indexes are used as input. | Reorganized primary index and database data set names Old or new secondary index data sets:
|