2 Feb 2020

  • February 02, 2020
  • Amitraj
B+ tree File Organization

-> B+ Tree is an advanced method of ISAM (Indexed sequential access method ) file organization. It uses the same concept of key-index, but in a tree like structure. 

-> B+ tree is similar to binary search tree, but it can have more than two children. It stores all the records only at the leaf node.  Intermediate nodes act as a pointer to the leaf nodes. They do not contain any records.





The above B+ tree shows that:

1. There is one root node of the tree, i.e., 25.

2. There is an intermediary layer with nodes. They do not store the actual record. They have only pointers to the leaf node.

3. The nodes to the left of the root node contain the prior value of the root and nodes to the right contain next value of the root, i.e., 15 and 30 respectively.

4. There is only one leaf node which has only values, i.e., 10, 12, 17, 20, 24, 27 and 29.

5. Searching for any record is easier as all the leaf nodes are balanced.


6. In this method, searching any record can be traversed through the single path and accessed easily.





Pros of B+ tree file organization -

1. Since all records are stored only in the leaf node and are sorted sequential linked list, searching is becomes very easy.

2. Traversing through the tree structure is easier and faster.

3. The size of the B+ tree has no restrictions, so the number of records can increase or decrease and the B+ tree structure can also grow or shrink.


4. It is a balanced tree structure, and any insert/update/delete does not affect the performance of tree.





Cons of B+ tree file organization -

1. This method is less efficient for static method.


Translate

Popular Posts