Validate 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. This check complements the validity checking performed by the VALIDATE TABLE statement.

Caution

Validate tables or entire databases only when no connections are making changes to the database.

 To validate an index (Sybase Central)
  1. Use the SQL Anywhere 12 plug-in to connect to the database as a user with DBA authority or as the owner of the table on which the index is created.

  2. In the left pane, double-click Indexes.

  3. Right-click the index and choose Validate.

  4. Click OK.

 To validate an index (SQL)
  1. Connect to the database as a user 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 (dbvalid utility)
  • Run a dbvalid command with the -i option specified.

 Example 1
 Example 2