8.9.6 idxwork statement (specification of directory for index information file)

The idxwork statement specifies the name of the directory to which the index information files created by the utility are to be output when the index or idxname statement is omitted.

Criterion
If you have specified neither the pd_tmp_directory operand in the system definition nor the TMP environment variable, you must specify the idxwork statement, if possible, in order to avoid a shortage of space in the %PDDIR%\tmp directory.
Rules
  1. If the index and idxwork statements are both omitted, the index information file is created in the directory shown in Table 8-40 Directory to which pdrorg outputs files on the server where the index RDAREA is located.
  2. You can specify as many idxwork statements as follows:
    HiRDB/Single Server
    Specify only one idxwork statement.
    HiRDB/Parallel Server
    For an index of a partitioned table, specify as many idxwork statements as there are servers that contain the table partitions. For a non-partitioned table or when reorganizing a partitioned table in units of RDAREAs, specify only one idxwork statement. You must specify the name of the server where the index RDAREA is located.
  3. If both idxwork and index statements are specified, the index statement takes effect, in which case the idxwork statement is ignored.
Organization of this subsection
(1) Format
(2) Explanation
(3) Notes

(1) Format

idxwork [server-name] directory-name

(2) Explanation

(a) server-name

~<identifier> ((1-8))

Specifies the name of the server used to create index information files.

HiRDB/Single Server
Do not specify this option. A single server name will be ignored, if specified.
HiRDB/Parallel Server
Specify the name of the server used to create index information files.
(b) directory-name

~<pathname> ((1-255))

Specifies the absolute path name of the directory in which index information files are to be created.

(3) Notes

The following shows the name of the index information file that is created automatically.

directory-name\INDEX-index-name-name-of-index-storage-RDAREA
-unique-character-string

Example:

If the idxwork statement specifies c:\hirdb\pdload as the directory name, IDX1 as the index name, and USER01 as the name of the index storage RDAREA, the created index information file will have the following name:

c:\hirdb\pdload\INDEX-IDX1-USER01-aaaa00001

Note
If an index name or an index storage RDAREA name contains a backslash (\) and \ is used in file path names, \ is treated as the path separator; therefore, \ is replaced with a left parenthesis (().