HDSORT


The HDSORT keyword is valid with the CLONE, RELOAD, REORG (Online Reorg function and Reorg function), and GROUP commands.

This keyword is available in PLUSIN; it is not available as a global option. The following table describes the keyword.

Table 1. Invoke HD Sort keyword

To do this

Specify this in PLUSIN

Invoke the standard HD Sort utility.

HDSORT(YES)

Do not invoke the standard HD Sort utility or the RAP Sequencer.

HDSORT(NO)

Allow the product to choose the optimum method (standard HD Sort utility or RAP Sequencer) if it can determine that a sort is needed.

HDSORT(AUTO)

Internal default: AUTO

You can include the HDSORT keyword with the RELOAD command or the REORG command, or you can invoke the HD Sort utility as a stand-alone utility before reloading the database. For more information, see HD-Sort-utility.

The HDSORT keyword invokes the standard HD Sort utility or the BMC RAP Sequencer, depending on which value you specify.

The HD Sort utility sorts an HD Unload data set into HDAM, PHDAM, HIDAM, PHIDAM, or HISAM order. It is a functional alternative to the IMS System Utilities/Database Tools HDAM Physical Sequence Sort/Reload (PSSR) utility.

The RAP Sequencer is an alternative to the HD Sort utility. The RAP Sequencer does not sort data; it places roots in root anchor point (RAP) sequence. Because the RAP Sequencer does not actually sort data, performance is better than the HD Sort utility. You cannot explicitly invoke the RAP Sequencer. When you specify HDSORT(AUTO), the product determines whether a sort is needed and which sort method is appropriate.

Specify HDSORT(AUTO), or accept it as the default, in the RELOAD or REORG job step if you did not invoke the HD Sort utility before reloading the database and you performed any of the following tasks:

  • Convert an HDAM database to HIDAM or HISAM (RELOAD only)
  • Convert an PHDAM database to PHIDAM (RELOAD only)
  • Convert a HIDAM or HISAM database to HDAM (RELOAD only)
  • Convert a PHIDAM database to PHDAM (RELOAD only)
  • Change the key of a root segment
  • Change the randomizer parameters for an HDAM or PHDAM database (except maximum insert bytes)

When you specify HDSORT(YES), the standard HD Sort utility is always invoked.

When you specify HDSORT(AUTO), the product determines whether the data needs to be sorted or resequenced and invokes the standard HD Sort utility or the RAP Sequencer, depending on what changed in the DBD. The product determines whether to sort the data or resequence the RAPs by comparing the new DBD to the DBD named in the OLDDBD keyword or the BMC unload header record DBD control blocks. If the product detects a DBD change that requires a sort and the following criteria are not met, the standard HD Sort utility is invoked. If the data is not in randomized sequence and the following criteria are met, the RAP Sequencer is invoked because it provides better performance:

  • The old DBD and the new DBD are HDAM or PHDAM.
  • The old DBD and the new DBD use the DFSHDC40 randomizer.
  • The root key position or length did not change.
  • The root key is not compressed.
  • The total number of RAPs increased.
  • You did not specify USERHDR when creating the HD Unload file.
  • The HD Unload file was created by the Unload function.

If the data was resequenced and the criteria for the RAP Sequencer was not met, the HD Sort utility must be invoked to sort the data before it is reloaded. Therefore, if any data in the key changed and the DBD did not change, or if any other changes occurred that the product cannot detect by examining the old DBD or the unload header record DBD control blocks, you must specify HDSORT(YES). Specifying HDSORT(AUTO) does not guarantee that a sort is performed.

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*

MAXM Reorg for IMS 5.0 and MAXM Reorg for IMS with Online/Defrag Feature 5.0