A relational index is an ordered set of pointers to rows in a table.
Each index is based on the values of data in one or more columns in a table. An
index is an object that is separate from the data in the table. When you create
an index, the database builds the structure and maintains it automatically. An
index can serve the following purposes:
Provide a fast way to find rows in a table based on their values in the key
columns. In some cases, all the information that a query needs can be found in
the index, making it unnecessary to read through the actual table.
Enforce uniqueness rules by defining a column or group of columns as a unique
index or primary key.
Provide a logical ordering of the rows of a table based on the key column
values.
Cluster the rows of a table in physical storage according to the order of the
defined index.
You can:
Create an index to improve performance.
Create a unique index to enforce uniqueness rules.
Drop an index.
The IBM® Database Add-Ins for Visual Studio provide three approaches
for creating a relational index in Visual Studio:
The IBM Table Designer, where you can define the index as part of a table
definition.
The Visual Studio Code Editor, where you can manually insert the SQL statement
in the index script file.
To develop an IBM database relational index in Visual Studio:
Create the index:
Use the IBM Table Designer to define the relational index while you are
creating a table.