Skip to content
tezvyn:

Databases & Architecture

SQL, NoSQL, system design, microservices, APIs

37 bites

Test yourself: Top 30 easy Databases & Architecture concepts questionsMultiple choice, with the correct answer and why it is correct on every question. Free, no sign-in.

Easy concepts in Databases & Architecture

DBMS: The Software That Runs Your Database
easy2 min read

DBMS: The Software That Runs Your Database

A DBMS is the software engine that manages a database, separating your app from raw data files. You use it to query, update, and administer data, like with PostgreSQL or MySQL. The common footgun is confusing the DBMS with the database itself.

DDL: The Blueprint for Database Objects
easy2 min read

DDL: The Blueprint for Database Objects

DDL is the blueprint for your database. You reach for it when spinning up new tables, indexes, or user permissions, not when querying rows. The footgun is running DROP thinking you are deleting data, not vaporizing the entire table structure.

easy2 min read

DML: Insert, Update, and Delete

DML is the change-focused subset of database languages like SQL that adds, modifies, and removes data. It appears in every write to a table. The footgun is assuming SELECT belongs in DML; read-only querying is sometimes split out as DQL instead.

easy2 min read

Primary Keys: The Unique ID for Every Row

A primary key is like a social security number for a database row, uniquely identifying it. It's used to reliably fetch records and link related data across tables. The footgun is using a natural key, like an email address, that might change over time.

Entity-Relationship Diagrams: A Blueprint for Your Data
easy2 min read

Entity-Relationship Diagrams: A Blueprint for Your Data

An Entity-Relationship Diagram (ERD) is a blueprint for a database, showing what you're storing and how it connects. It's used before writing code to design a relational database schema. The main footgun is designing the model to match the UI, not the data.

easy2 min read

First Normal Form (1NF): No Nested Data

First Normal Form (1NF) means every table cell holds one single value, not a list. It's the first rule of relational databases, stopping you from storing comma-separated strings. The footgun is stuffing multiple values into one field, which breaks SQL queries.

Junction Table: Connecting Many to Many
easy2 min read

Junction Table: Connecting Many to Many

A junction table is a bridge between two other tables, enabling a many-to-many relationship. It's used to connect students to classes or tags to articles. The common footgun is forgetting a unique constraint, allowing duplicate connections.

easy2 min read

Lock Now or Check Later: Optimistic vs. Pessimistic Concurrency

Pessimistic concurrency locks data first, assuming conflict is likely ('ask permission'). Optimistic concurrency proceeds without locks and checks for conflicts before saving, assuming they're rare ('ask forgiveness'). Use pessimistic for high-contention.

easy2 min read

Write-Ahead Logging (WAL): Survive Crashes by Journaling First

Think of it as a journal of intentions. Before changing data, a database writes the intended change to a log file first. This ensures that if the system crashes, it can recover by replaying the log, guaranteeing no writes are lost.

easy2 min read

Database Transaction Log: Your System's Safety Net

A transaction log is your database's safety journal. Before changing data, it records the intended action in a durable file. This is vital for crash recovery, ensuring data isn't left corrupt. The footgun: its primary role is integrity, not just auditing.

Shared & Exclusive Locks: The Read vs. Write Rule
easy2 min read

Shared & Exclusive Locks: The Read vs. Write Rule

A Shared (S) lock is like many people reading a library book at once; an Exclusive (X) lock is one person writing in it alone. Databases use S/X locks to manage concurrency, preventing writes from corrupting reads.

easy2 min read

Query Execution Plan: The Database's Road Map

A query execution plan is the database's internal strategy for fetching your data. It's the recipe it creates before running your SQL. This plan determines whether to use an index or scan a whole table, directly impacting performance.

easy2 min read

B-Tree: The Workhorse of Database Indexes

A B-tree is a self-balancing tree that keeps data sorted for fast lookups, generalizing a binary search tree by allowing nodes to have many children. It enables searches, insertions, and deletions in logarithmic time, making it ideal for large datasets.

Row Mode vs. Batch Mode Execution in SQL Server
easy2 min read

Row Mode vs. Batch Mode Execution in SQL Server

Row mode processes data one row at a time, like a checklist. Batch mode processes chunks of rows together for vectorized speed. Row mode is classic for OLTP, while batch mode shines in data warehousing for large scans.

easy2 min read

Storage Engine: The Database's Filing System

A database's storage engine is its specialized filing system, handling how data is physically written to and read from disk. Different engines optimize for different tasks, from fast writes to complex queries.

easy2 min read

Row vs. Columnar Storage: Organizing Data for Speed

Row stores group data by record, like a phone book entry. Column stores group by attribute, like separate lists for all names. Use row stores for transactions (OLTP), but for analytics (OLAP), they force you to read unneeded data from disk.

Database Pages: The Building Blocks of Your Data
easy2 min read

Database Pages: The Building Blocks of Your Data

A database page is the fundamental 8KB block for all storage. The database engine reads and writes entire pages, not single rows, for user data, indexes, and metadata. The key footgun: the physical order of rows on a page is not guaranteed.

How SQL Queries Become Abstract Syntax Trees
easy2 min read

How SQL Queries Become Abstract Syntax Trees

An AST turns a flat SQL string into a tree of operations the database can reason about. The parser builds this tree before execution planning. Do not confuse it with the raw parse tree, which keeps punctuation and formatting the AST strips away.

easy2 min read

Nested Loop Join: The Brute-Force Database Join

A nested loop join is the brute-force way to match two tables. For each row in the first table, it scans every row in the second. It's simple and effective for small tables but its performance degrades quadratically on large datasets.

easy2 min read

NoSQL: Databases Beyond Rigid Tables

NoSQL databases trade rigid tables for flexible models like documents or key-value pairs. This allows them to scale for massive, unstructured datasets from social media or IoT.

We are hiring for this. Every open role lists the topics its interview covers, so you can prepare for the real thing rather than guessing.

See open roles