System Design Space
Knowledge graphSettings

Updated: February 24, 2026 at 4:55 PM

Guide to Databases (short summary)

mid

Official source

Postgres Pro

Free electronic version of the book on the Postgres Professional website.

Download for free

Guide to Databases

Authors: V. I. Komarov
Publisher: DMK Press, 2024
Length: 520 pages

Tutorial from PostgreSQL: relational model, SQL, DBMS architecture, distributed systems and NoSQL.

Guide to Databases - original coverOriginal

Why read this book?

The book is ideal for those who want:

  • Get fundamental knowledge - understand the theoretical foundations of DBMS, from relational algebra to transactional processing
  • Master SQL at a professional level - from basic queries to complex window functions and recursive CTEs
  • Understand the architecture of the DBMS — how indexes, transactions, replication and distributed systems work
  • Prepare for the interview - the book covers all database topics that are asked about System Design

Related chapter

PostgreSQL from the inside

Deep dive into MVCC, WAL, locks and PostgreSQL indexes from Egor Rogov.

Читать обзор

Features of the book

Educational format

The book is written as a textbook with practical tasks, test questions and laboratory work. Ideal for self-study.

Relevance

Covers modern topics: NoSQL databases, distributed systems, big data processing, CAP theorem and eventual consistency.

Practical Focus

The theory is supported by examples in PostgreSQL. All concepts can be immediately put into practice with a real DBMS.

Free access

The book is available for free in electronic format on the Postgres Professional website - a quality resource without barriers.

Related chapter

Database Internals

Deep dive into B-Trees, LSM-Trees and distributed systems from Alex Petrov.

Читать обзор

Book structure

Part I: Introduction to Databases

Fundamentals of database theory: from file systems to DBMS, relational model, normalization, ER diagrams and schema design.

Relational model

Codd, relationships, keys

Normalization

1NF → BCNF, denormalization

ER modeling

Entities, relationships, attributes

Design

Logical and physical model

Part II: SQL Language

Complete SQL course: from SELECT to complex analytical queries, DDL/DML, window functions, CTE and query optimization.

DML operations

SELECT, INSERT, UPDATE, DELETE

JOIN and subqueries

INNER, LEFT, RIGHT, FULL, CROSS

Window functions

ROW_NUMBER, RANK, LAG, LEAD

CTE and recursion

WITH, recursive queries

Part III: DBMS Architecture

DBMS internals: data storage, indexes, buffer cache, transactions, locks and failure recovery.

Data storage

Pages, heap, TOAST

Indexes

B-Tree, Hash, GiST, GIN

Transactions

ACID, isolation levels

WAL and recovery

Logging, checkpoint

Part IV: Distributed Systems

Replication, sharding, distributed transactions, CAP theorem, consensus and modern approaches to scaling.

Replication

Master-Slave, Master-Master

Sharding

Horizontal partitioning

CAP theorem

Consistency, Availability, Partition

Consensus

Paxos, Raft, 2PC

Part V: NoSQL and Big Data

Alternatives to relational DBMS: document stores, key-value, column-family, graph databases and big data ecosystem.

Document stores

MongoDB, CouchDB

Key-Value

Redis, Memcached, DynamoDB

Column-family

Cassandra, HBase

Graph databases

Neo4j, JanusGraph

Сравнение типов NoSQL баз данных

Document Store

Документы (JSON/BSON) с вложенной структурой. Гибкая схема, богатые запросы по полям.

Примеры

MongoDBCouchDBFirestoreElasticsearch

Use Cases

КаталогиCMSUser profilesEvent logging

Модель данных

JSON/BSON документы

Query Pattern

Запросы по полям, индексы

Consistency

tunable

Транзакции

ХарактеристикаKey-ValueDocument StoreColumn-FamilyGraph Database
МасштабированиеHorizontalHorizontalHorizontalBoth
Консистентностьeventualtunabletunablestrong
Схемаschemalessflexibleflexibleflexible
Транзакции
JOINs

💡 Когда выбирать NoSQL вместо SQL?

  • Key-Value: нужна максимальная скорость и простые lookup-операции
  • Document: гибкая схема, nested data, эволюция структуры
  • Column-Family: write-heavy workloads, time-series, огромные объёмы
  • Graph: сложные связи между сущностями, многоуровневые обходы

Key Concepts for System Design

🔑Selecting a database type

  • OLTP vs OLAP - different load patterns
  • SQL vs NoSQL - trade-offs for different tasks
  • Polyglot persistence - different databases for different data
  • NewSQL - the best of both worlds

📊Indexing

  • B-Tree for range queries and equality
  • Hash for point lookups
  • Composite indexes - column order is important
  • Covering indexes - avoiding heap lookup

Scaling

  • Read replicas - read scaling
  • Sharding - horizontal scaling
  • Partitioning - managing large tables
  • Connection pooling — PgBouncer, ProxySQL

🔒Consistency

  • ACID - Transaction Guarantees
  • Insulation levels - trade-off with performance
  • Eventual consistency in distributed systems
  • Saga pattern for distributed transactions

Who is this book for?

For beginners

Students and developers without database experience

Backend developers

To systematize knowledge and fill gaps

Preparing for an interview

Comprehensive coverage of database topics

About the authors

The book was written by a team of authors from the company Postgres Professional - a leading Russian developer of solutions based on PostgreSQL. The company is known for its contributions to the development of PostgreSQL and the creation of educational materials of the highest quality.

Where to find the book

Verdict

The Database Guide is an excellent free resource for those who want to gain fundamental knowledge about databases in Russian. The book is especially valuable as a textbook: its structured presentation, practical tasks and relevant content make it an ideal choice for self-study. Recommended as a first step before diving into more specialized books like DDIA or Database Internals.

Related chapters

Enable tracking in Settings

System Design Space

© 2026 Alexander Polomodov