Contents Index Creating indexes Dropping indexes

ASA SQL User's Guide
  Working with Database Objects
    Working with indexes

Validating indexes


You can validate an index to ensure that every row referenced in the index actually exists in the table. For foreign key indexes, a validation check also ensures that the corresponding row exists in the primary table, and that their hash values match. This check complements the validity checking carried out by the VALIDATE TABLE statement.

To validate an index (Sybase Central)

  1. Connect to a database with DBA authority or as the owner of the table on which the index is created.

  2. In the left pane, open the Indexes folder.

  3. Right-click the desired index and choose Validate from the popup menu.

To validate an index (SQL)

  1. Connect to a database with DBA authority or as the owner of the table on which the index is created.

  2. Execute a VALIDATE INDEX statement.

To validate an index (command line)

  1. Open a command prompt.

  2. Run the dbvalid utility.

Examples 

Validate an index called EmployeeIndex. If you supply a table name instead of an index name, the primary key index is validated.

VALIDATE INDEX EmployeeIndex

Validate an index called EmployeeIndex. The -i switch specifies that each object name given is an index.

dbvalid -i EmployeeIndex

For more information, see VALIDATE INDEX statement, and The Validation utility.


Contents Index Creating indexes Dropping indexes