DatabasesLesson 2 of 3 in the course NoSQL and indexing

B-tree Structure, Indexing, Updates, and Variants

5 flashcards · 5 quiz questions · 5 match pairs · 5 fill-in sentences · English

Lesson progress
0 / 5

Your progress is kept in this browser only.Sign up to save it

Summary

A B-tree is a balanced search-tree structure designed to keep ordered data searchable as it grows. Its ability to store multiple keys and child pointers in each node makes it especially useful when data is organized in disk pages or memory blocks.

A B-tree is a self-balancing tree data structure that maintains sorted data. It supports searching, sequential access, insertion, and deletion in logarithmic time. Unlike a binary search tree, whose nodes typically have at most two children, a B-tree node can have many children.

All flashcards

What is a B-tree?
A self-balancing search tree that stores ordered keys in nodes with multiple keys and children.
Why are B-trees effective for storage systems?
They use each fetched block for many keys and child references, reducing costly block accesses.
What does equal leaf depth ensure in a B-tree?
Search paths reach the bottom after the same number of levels.
Why should the meaning of B-tree order be checked?
Authors use different conventions, including maximum children or minimum keys.
How can a file system use a B-tree?
It can organize mappings from logical file-block numbers to physical disk-block addresses.

Quiz questions

  1. In a B-tree internal node with k children, how many separator keys does it contain?Answer: One fewer key than children.
  2. Under Knuth's convention, what does the order m of a B-tree specify?Answer: The maximum number of children per node.
  3. Which method is often used to locate a separator within a B-tree node?Answer: Binary search over the node's ordered keys.
  4. During insertion, when can a B-tree's height increase?Answer: When a split reaches the root and creates a new root.
  5. Where does a B+ tree store record pointers?Answer: In its leaves, while internal nodes direct searches.

Based on the Wikipedia article B-tree, licensed CC BY-SA 4.0. Adapted into a summary, flashcards and quizzes.

All Databases lessons