Non-unique indexes – HP R4.2 User Manual

Page 251

Advertising
background image

5

Database Administration

Call Data Tables

UCS 1000 R4.2 Administration 585-313-507

Issue 3 April 2000 212

4

Enter
create unique index index_name on table_name (“FIELD1”);

The system creates a unique index for FIELD1 in the table.

Non-Unique Indexes

Non-unique indexes do not prevent the same data from appearing in that field
in several records in the same table. For example, if a field contains the area
code of a telephone number and an index is created for that field, it must be a
non-unique index since other records may require the same number in their
area code field.

Use the following procedure to create non-unique indexes on fields called

FIELD1

and

FIELD2

in a table called

table_name

:

1

At the

Console Login:

prompt, enter root

The system prompts you for a password.

2

Enter your root password.

The system displays the system prompt

#

.

3

Enter sqlplus sti/sti

The system starts a sqlplus session.

4

Enter create index index_name on table_name (“FIELD1”);

The system creates a non-unique index for FIELD1 in the table.

Advertising