My favorite metaphor for explaining indexes is comparing them to index cards in an old library. In an old library, you used to (or still do) have index cards at the front desk which have some brief description of the books in the library. They also used to be categorized alphabetically.
(image taken from http://www.flickr.com/photos/reedinglessons/2239767394/)
Let’s pretend that you are simulating an application that is trying to find a book with a certain title in the library.
Not using an index
If you are not using the index cards, you would have to go shelf by shelf and row by row, look at each book’s title and see if its the one you need. This is very time consuming and is similar to how a database looks at blocks on the hard disk when its not using an index.
Using an …
[Read more]