views:

31

answers:

1

This is related to primary database indexing mechanism (sparse indexing).

Binary search can be used on the index file to locate an entry. But, if overflow blocks have been used, binary search will not be possible.

Could someone explain how overflow blocks make binary search not possible to use?

A: 

Overflow blocks are created when there is insufficient space in an indexed block to create a new record.

Overflow blocks cannot be binary searched because they are not part of the primary indexing/linked list scheme (i.e. not binary indexed). Instead, they are attached to (associated with) primary blocks that are part of the indexing scheme.

To get to them, you have to do a binary search to find the closest index block, and then search through the overflow blocks sequentially to find the one you want.

If you wish, you can index the overflow blocks to make them first-class citizens (part of the binary search), but then they are not overflow blocks anymore.

Robert Harvey