JCL requirements for the HD Sort utility


The following figure shows generic JCL for executing the HD Sort utility.

       //HDSORT   JOB (acct),'userName',MSGCLASS=m,NOTIFY=user,CLASS=c
//SORT     EXEC PGM=HDSORT
//STEPLIB  DD DISP=SHR,DSN=bmc.xxx.load
//         DD DISP=SHR,DSN=IMS.RESLIB
//DFSRESLB DD DISP=SHR,DSN=IMS.RESLIB
//IMS      DD DISP=SHR,DSN=ims.dbdlib.new
//RECON1   DD DISP=SHR,DSN=your.recon1       <===for HALDB only; required
//RECON2   DD DISP=SHR,DSN=your.recon2       <===for HALDB only; required
//RECON3   DD DISP=SHR,DSN=your.recon3       <===for HALDB only; required
//SORTIN   DD DISP=SHR,DSN=database.hdunld.unsorted,DISP=SHR
//SORTOUT  DD DSN=database.hdunld.sorted,DISP=(NEW,CATLG),UNIT=TAPE
//BMCPRINT DD SYSOUT=*
//PLUSIN DD *
  SORT DBD(HDAMDB)
//SORTWK01 DD  SPACE=(CYL,(75,10)),UNIT=SYSDA
//SORTWK02 DD  SPACE=(CYL,(75,10)),UNIT=SYSDA
//SORTWK03 DD  SPACE=(CYL,(75,10)),UNIT=SYSDA
//SORTWK04 DD  SPACE=(CYL,(75,10)),UNIT=SYSDA
//SORTWK05 DD  SPACE=(CYL,(75,10)),UNIT=SYSDA
//SORTWK06 DD  SPACE=(CYL,(75,10)),UNIT=SYSDA
//SYSOUT   DD  SYSOUT=*

An explanation of the JCL follows:

EXEC

Required. The EXEC statement must specify PGM=HDSORT. The HD Sort utility does not run under the IMS region controller (DFSRRC00).

STEPLIB DD

Required. Include the following libraries in the concatenation:

  • The BMC load library
  • Library containing the HDAM randomizer


Note

Because the sort product does not search the LNKLST concatenation, this statement is required even if the BMC load library is included in the LNKLST concatenation.

IMS DD

Required. Describes the IMSVS.DBDLIB data set that contains the DBD that will be used to sort the unsorted unload file into sequence.

RECONx DD

Required for HALDBs. Defines the DBRC RECON data sets.

SORTIN DD

Required. Defines the input data set that contains the HD Unload-format records that you want the HD Sort utility to sort. The HD Unload data set can be created by the following utilities:

  • Unload function. The HD Sort utility supports the abbreviated records that the Unload function creates with the DFSURGU1(LONG), DFSURGU1(SHORT), DFSURGU1(XSHORT), and USERHDR options. It also supports the compressed records that the Unload function creates with the EXPAND(NO) option. If the HD Unload data set was created by the Unload function but the header records were deleted by the user, the records must be in DFSURGU1(LONG) format for the HD Sort utility to sort them correctly. If the header record has been deleted and the USERHDR keyword is not specified with the SORT command, the HD Sort utility assumes that the records are in DFSURGU1(LONG) format.
  • IMS HD Reorganization Unload utility
  • High Speed Sequential Retrieval (HSSR) feature of the IMS System Utilities/Database Tools package
  • Any other utility that creates HD Unload-format records

SORTOUT DD

Required. Defines the output data set to contain the sorted HD Unload-format records. You can use this data set as input to the following utilities:

  • The Reload function
  • The IMS HD Reorganization Reload utility
  • Any other utility that reads HD Unload-format records

DFSPARM DD

Required when you use the HD Sort utility with DFSORT and VLSHRT(YES) is the DFSORT default. Specify the following statement:

//DFSPARM DD *
   OPTION NOVLSHRT

BMCPRINT DD

Optional. For more information, see BMCPRINT-DD.

SORTWKnn DD

Optional. If you specify the SORTWORK option, the Reload function dynamically allocates the sort work data set. Defines the sort work areas that your site’s sort/merge utility uses to sort the HD Unload-format records. For more information, see the documentation for your site’s sort/merge utility.

SYSOUT DD

Required. Defines the print data set to contain messages from the sort/merge utility. It is normally a SYSOUT-type data set.

PLUSIN DD

Required. Defines the data set that contains the control statements for the HD Sort utility. You must include a control statement in the PLUSIN data set to identify the DBD name of the database to sort. You can also include keywords to override the existing HDAM or PHDAM randomizer parameters. These keywords allow you to run the DBDGEN after the HD Sort utility step; however, you normally should run the DBDGEN before the HD Sort utility step.

Note

The SORT command is required.

The following table describes the valid keywords.

PLUSIN DD keywords

Keyword

Description

DBD

Required. Specify the DBD name of the database. This name normally refers to the new DBD. There is no default value.

If you enter a different DBD name on the control statement than the DBD that was used to create the HD Unload data set, the HD Sort utility uses the randomizing parameters from the DBD that is named in the control statement.

DFSDBUX1

Optional. Specify whether to use the DFSDBUX1 user exit. For more information, see DFSDBUX1.

DESCCODE

Optional. Specify a descriptor code. For more information, see MONITOR-MONUSERS-ROUTCODE-DESCCODE.

FLATFILE(nnnnn)

Optional. This keyword indicates that the data set specified in the SORTIN DD contains records with HDAM root keys at offset 'nnnnn'.

  • The remainder of the record is not examined and can be any application required data.
  • The SORTIN file will be sorted into HDAM RAP/root key order.
  • Offset 'nnnnn' is relative to 1, which means that if the root key is the first character in the record, the keyword should be FLATFILE(1). Both fixed and variable format files are accepted. If the file is variable length, the 'nnnnn' value does not include the four-byte record length prefix.
  • Output is written to a SORTOUT DD, which must be included in the job step's JCL. Parameter DBD(dbdname) is required, and a matching DBD must exist in the IMS DD.
  • The SORTIN DD must not include unload header records nor non-root segments when you use FLATFILE.

HDPRINT

Optional. Specify an output data set. For more information, see xxxPRINT.

KEYLEN

Optional. Specify a value (1-3 digits) for the length (in bytes) of the root segment’s key field. Valid values range from 1 to 255 (inclusive). Leading zeros are not required. The default value is the key length that is specified in the DBD.

LOWLEVEL

Optional. This keyword tells the HDSORT utility to sort the unload file by using all segment key fields instead of only the root key field (or the root key's randomized value if HDAM).

Warning

The limitation for this keyword is that the sort record must be shorter than 32756 bytes. This total includes the largest possible segment, plus the longest possible concatenated key, plus additional overhead of either 63 or 67 bytes.

MONITOR

Optional. Specify a monitoring interval. For more information, see MONITOR-MONUSERS-ROUTCODE-DESCCODE.

MONUSERS

Optional. Specify a TSO user ID to receive monitoring messages. For more information, see MONITOR-MONUSERS-ROUTCODE-DESCCODE.

NBLOCKS

Optional. Specify a value (1-8 digits) for the maximum RBN allowed for the database. This keyword is ignored if the DBD is not HDAM or PHDAM. Valid values range from 1 to 16777215 (inclusive). Leading zeros are not required. Do not code commas within the value (for example, code 215610 instead of 215,610). The default value is the maximum RBN that is specified in the DBD.

NRAPS

Optional. Specify a value (1-3 digits) for the number of RAPs in each CI or block in the RAA of an HDAM or PHDAM database. This keyword is ignored if the DBD is not HDAM or PHDAM. Valid values range from 1 to 255 (inclusive). Leading zeros are not required. The default value is the number of RAPs that are specified in the DBD.

RMNAME

Optional. Specify the name (1-8 characters) of an HDAM or PHDAM randomizing module. This keyword is ignored if the DBD is not HDAM or PHDAM. The default value is the name of the randomizer as it is specified in the DBD.

SORTWORK

Optional. Specify a sort work data set. For more information, see SORTWORK.

USERHDR

Optional. Specify a user-defined prefix. For more information, see USERHDR.


Related topic


 

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