Previous Topic: KEEP LONGTERM (DC/UCF)Next Topic: MAP IN (DC/UCF)


LOAD TABLE (DC/UCF)

The LOAD TABLE statement instructs the system to load a table (module or program) into the program pool.

Syntax
►►── LOAD TABLE (table-name) POINTER (table-location-pointer)  ─┬──────────┬;─►◄
                                                                ├─ WAIT ◄ ─┤
                                                                └─ NOWAIT ─┘
Parameters
table-name

Specifies the 1- to 8-character name of the table to be loaded. Table is either the symbolic name of a user-defined field that contains the table, or the name itself enclosed in single quotation marks.

POINTER (table-location-pointer)

Specifies the pointer variable for referencing the loaded table. After the table has been loaded, the pointer contains the address of the beginning of the table.

WAIT

Requests the issuing task to wait until sufficient storage becomes available. If WAIT is specified and the system encounters an insufficient storage condition, the issuing task is placed in an inactive state; when the LOAD TABLE function is completed, control returns to the issuing task according to its previously established dispatching priority. WAIT is the default.

NOWAIT

Requests the issuing task not to wait for storage to become available. If NOWAIT is specified, the system returns a value of 3402 to the ERROR_STATUS field when an insufficient storage condition exists.

Example

The following source code defines the data required for use with the LOAD TABLE request:

DCL STATECON_POINTER POINTER;
   DCL 1 STATECON(50) BASED (STATECON_POINTER),
      3 STATE_ABB CHAR(2),
      3 STATE_FULL CHAR(15);

The following statement loads the STATECON table into the program variable-storage area identified by the pointer STATECON_POINTER:

LOAD TABLE (STATECON)
   POINTER (STATECON_POINTER);
Status Codes

Upon completion of the LOAD TABLE function, the ERROR_STATUS field in the IDMS DC communications block indicates the outcome of the operation:

0000

The request has been serviced successfully.

3401

The requested module cannot be loaded immediately due to insufficient storage; to wait would cause a deadlock.

3402

The requested module cannot be loaded because insufficient storage exists in the program pool.

3407

The requested module cannot be loaded because an I/O error has occurred during processing.

3414

The requested module cannot be loaded because it has been defined as noncurrent and is currently in use.

3415

The requested module has been overlaid temporarily in the program pool and cannot be reloaded immediately.

3436

Either the requested program is not defined in the program definition table (PDT) and is marked out of service, or null PDEs are not specified or valid in this system.