CREATE INDEX
- Last Updated: January 17, 2024
- 1 minute read
- OpenEdge
- Version 12.8
- Documentation
The CREATE INDEX statement creates
an index on one or more columns of a table. You can specify an index
in ascending order (ASC) or descending order (DESC).
A DBA must use the FOR TENANT phrase to over-ride
the default index storage areas and allocate new database storage
areas for the index. A multi-tenant index is generated for a multi-tenant
table.
CREATE
INDEX statement, see OpenEdge SQL Reference.Syntax
The CREATE INDEX statement uses the following
syntax:
|
Syntax to create a global index
The following syntax is used to create a global index:
|
Example: CREATE INDEX statement
The index in this CREATE INDEX example is specified
on the single column empno, and is of ascending
order on the value of the column, as shown in the following example.
|
Example: Creating a multi-tenant index
The following example shows how to define a multi-tenant index:
|
Example: Creating local indexes for a partitioned table
The following example shows how to create local indexes for the
partitioned table Pub.tpcustomer with partitions:
|
Example: Creating a global index for a partitioned table
The following example shows how to create local indexes for the
partitioned table Pub.tpcustomer with partitions:
|
For details on using the CREATE INDEX
statement to enable transparent data encryption, see Learn
about Security and Auditing.
For details on using the CREATE INDEX
statement to designate objects for buffer pool assignments, including an alternate buffer
pool, see Manage OpenEdge Databases.