Restriction: This topic applies to Windows environments only.
To create an index or key on a table in the current location:
- From the main menu, click
Run > Tools > Data Tools > SQL Option for DB2 > Client > SQL Wizard.
- If the Catalog Browser window is not open, click
to open it.
- On the Catalog Browser window, ensure the
Table tab is selected.
- Click the table you want.
- Click
Alter.
- Click
Create in the
Indexes and Keys group.
- Type a name for your index or key.
- Select the type of index or key you want to create.
- Use the arrow pushbuttons to create a list of columns that define the index or key.
- When you have finished, click
OK to close the Create Index dialog box.
You can look at the SQL statements that will be used to make your changes by clicking
SQL.
- Click
OK to close the Alter Table window.