10.3.5 sort statement (specification of work directory for sorting)

The sort statement specifies information about a work file for sorting that is used when an index is created in the batch index creation mode (-i c).

Criterion
If you have specified neither the pd_tmp_directory operand in the system definition nor the TMPDIR environment variable, you must specify the sort statement, if possible, in order to avoid a shortage of space in the /tmp directory.
Rules
  1. If the sort statement is omitted, the utility assumes the directory shown in Table 10-2 Directory to which pdrbal outputs files as specified by the server on the server where the index storage RDAREA is located.
  2. The work file for sorting is deleted automatically when pdrbal processing terminates.
  3. For a HiRDB single server configuration, specify only one sort statement.
    For a HiRDB parallel server configuration, specify as many sort statements as there are servers that contain the index storage RDAREAs added by ALTER TABLE.
Organization of this subsection
(1) Format
(2) Explanation
(3) Note

(1) Format

sort [server-name] directory-name

(2) Explanation

(a) server-name

~<identifier> ((1-8))

Specify the name of the server used to create the work file for sorting.

For a HiRDB single server configuration, do not specify the server name.

(b) directory-name

~<pathname> ((1-255))

Specify the absolute pathname of the directory in which the sort work file is to be created.

(3) Note

Do not allocate NFS to the directory specified in the sort statement. If NFS is allocated, twice as much space is required for the work file for sorting as when a local file is used. Also, problems occur related to retention of work files for sorting.