Determining which logical indexes share a physical index

When you drop an index, you are dropping a logical index; however, you are not always dropping the physical index to which
it refers. If another logical index refers to the same physical index, the physical index is not deleted. This is important
to know, especially if you expect disk space to be freed by dropping the index, or if you are dropping the index with the
intent to physically recreate it.

To determine whether an index for a table is sharing a physical index with any other indexes, select the table in Sybase Central,
and then click the Indexes tab. Note whether the Phys. ID value for the index is also present for other indexes in the list. Matching Phys. ID values
mean that those indexes share the same physical index. If you want to recreate a physical index, you can use the ALTER INDEX
... REBUILD statement. Alternatively, you can drop all the indexes, and then recreate them.

Determining tables in which physical indexes are being shared

At any time, you can obtain a list of all tables in which physical indexes are being shared, by executing a query similar
to the following:

The number of rows for each table indicates the number of shared physical indexes for the tables. In this example, all the
tables have one shared physical index, except for the fictitious table, MAINLIST, which has two. The phys_index_id values
identifies the physical index being shared, and the value in the COUNT column tells you how many logical indexes are sharing
the physical index.

You can also use Sybase Central to see which indexes for a given table share a physical index. To do this, choose the table
in the left pane, click the Indexes tab in the right pane, and then look for multiple rows with the same value in the Phys. ID column. Indexes with the same
value in Phys. ID share the same physical index.