Table Indices (ttadv4121s000)

Use this session to define indices for the table from which the session is started.

An index is used to sort and search records.

Each table must have at least one index. The first index is always the primary key. The primary key field(s) form the unique identification for each record in the table. You can add indices to the table when application demands make this necessary.

Note: 

Tools displays the table for which the indices and the VRC code are defined.

  • Enter the number of the index and the description.
  • Specify the index parts, which are the names of existing table fields.
  • Specify whether duplicates are accepted, and whether the index is active.

Field Information

Table

The code of the package, for which the table is defined.

Table

The module code of the table.

Table

The identification code of the table for which the index has been defined.

A table is uniquely identified by this code in combination with the package and module codes.

VRC

The VRC is the version of the package for which Tools defines the table.

VRC

The release of the package for which the table is defined.

VRC

The customer extension of the package for which the table is defined.

Index Number

The number of the index, which is a unique number within the table. The primary key always has index number one.

Index Parts

An index part is the name of a table field defined in the Table Fields (ttadv4122s000) session.

Note: 

An index can consist of up to 24 logical parts. The maximum number of physical parts is eight. Adjacent index parts of the type string, enumerate, or byte can be optimized into one physical part if they are also adjacent in the table definitions. (Only for ISAM database organizations).

For example
logp = logical part
physp = physical part

Logical part = Table field (part of index) Physical part= Adjacent table fields (parts of an index)

Duplicates

If this check box is selected, different records can have the same values in the index parts. These are called duplicate records.

Active

If this check box is selected, the index is active. The primary index (index number 1) is always active.

Note: This information is not used in the data dictionary or the database layer.