If redistribu6on fails merge l and sibling if merge

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: up and s continues to appear in the leaf.) 5 2* 3* 5* 17 5 13 24 7* 8* Entry to be inserted in parent node. (Note that 17 is pushed up and only appears once in the index. Contrast this with a leaf split.) 30 Example B+ Tree AVer Inser6ng 8* Root 17 5 2* 3* 24 13 5* 7* 8* 14* 16* 19* 20* 22* 30 24* 27* 29* 33* 34* 38* 39*   Notice that root was split, leading to increase in height.   In this example, we can avoid split by re-distributing however, this is usually not done in practice. entries; Dele6ng a Data Entry from a B+ Tree •  Start at root, find leaf L where entry belongs. •  Remove the entry. –  –  If L is at least half ­full, done! If L has only d ­1 entries, •  Try to re ­distribute, borrowing from sibling (adjacent node with same parent as L). •  If re ­distribu6on fails, merge L and sibling. •  If merge occurred, must delete entry (poin6ng to L or sibling) from parent of L. •  Merge could propagate to root, decreasing height. Example Tree AVer (Inser6ng 8*, Then) Dele6...
View Full Document

This document was uploaded on 03/12/2014 for the course CSCI 165B at UC Davis.

Ask a homework question - tutors are online