Basic HTML version of Foils prepared 7 October 97

Foil 30 When Should one Create Indices ?

From Untitled presentation ARL Database Tutorial -- February 98. by Gang Cheng, C.W. Ou, Geoffrey C. Fox


An Index can improve the performance of queries that select a small percentage of rows from a table. A general guideline is to create indexes on tables that are queried for less than 2% - 4% of the table's rows, with the following assumptions:
  • Rows with the same value for the column on which the query is based are uniformly distributed throughout the data blocks allocated to the table
  • Rows in the table are randomly ordered with respect to the column on which the query is based
  • Each data block allocated to the table contains at least 10 rows
  • The table contains a relatively small number of columns
  • Most queries on the table have relatively simple WHERE clauses



© Northeast Parallel Architectures Center, Syracuse University, npac@npac.syr.edu

If you have any comments about this server, send e-mail to webmaster@npac.syr.edu.

Page produced by wwwfoil on Tue Jan 27 1998