development
A Programming Odyssey


sqlmini

A Database Management System (DBMS) inspired by SQLite3 written in C.

Capable of the INSERT and SELECT SQL statements for a pre-determined row layout. Stores a table across multiple memory pages to allow caching of visited rows and stores pages in a B-Tree enabling efficient key lookup.

Internal Tree Structure

The internal datbase stores the database contents in a B-Tree structure with the following structure.

Example B-Tree Structure

Source: 'Part 7 - Introduction to the B-Tree'

This is what the an example tree looks like when printed out using the .btree meta command.

btree print-out example

Credit

sqlmini is built following the online book 'Let's Build a Simple Database' written by cstack.