A comprehensive, interactive study guide for database interviews covering SQL, NoSQL, indexing, performance, architecture, and more — from Trainee to Lead level.
- 📖 60+ Topics — Database fundamentals, SQL language, indexing, NoSQL, ClickHouse, Elasticsearch, NewSQL, and more
- 🏭 Real Production Examples — Instagram, Netflix, Uber, Stripe, Cloudflare, GitHub, and many more
- ✅ Progress Tracking — Check off topics as you study with visual progress
- 🧭 Interactive DB Selector — Answer 5 questions, get a personalized database recommendation
- ⚡ Rapid-Fire Cheat Sheet — Click-to-reveal one-liner answers for speed rounds
- 🔍 Search & Filter — Search any topic, filter by experience level (Trainee → Lead)
- 📱 Responsive — Works on desktop and mobile
| Section | Topics |
|---|---|
| Database Fundamentals | SQL vs NoSQL, ACID, BASE, Isolation Levels |
| SQL Language | DDL, DML, SELECT, JOINs, GROUP BY, CTEs, Window Functions |
| Indexing | B-Tree internals, all index types (GIN, GiST, BRIN), strategies, EXPLAIN |
| NoSQL | MongoDB, Redis, Cassandra, Neo4j, ClickHouse, Elasticsearch |
| NewSQL & Cloud | CockroachDB, TiDB, Spanner, Snowflake, BigQuery |
| Normalization | 1NF→BCNF, data types, denormalization patterns |
| Procedures & Triggers | Functions, stored procedures, triggers, views |
| MVCC & Transactions | PostgreSQL internals, VACUUM, locking, deadlocks |
| Security | SQL injection, roles, row-level security, encryption |
| Design Patterns | Soft deletes, event sourcing, CQRS, EAV, polymorphic |
| Performance | Query optimization, cursor pagination, partitioning, sharding |
| Tricky Questions | NULL traps, NOT IN gotcha, Nth salary, architecture gotchas |
| Model Answers | "When would you choose NoSQL?", "Design a database for X" |
# Clone the repo
git clone https://github.com/YOUR_USERNAME/db-interview-prep.git
cd db-interview-prep
# Install dependencies
npm install
# Start dev server
npm run devOpen http://localhost:5173 in your browser.
npm run buildOutput goes to dist/ folder.
- Push this repo to GitHub
- Go to Cloudflare Dashboard → Workers & Pages → Create
- Select Pages → Connect to Git
- Select your repository
- Set build settings:
- Framework preset: Vite
- Build command:
npm run build - Build output directory:
dist
- Click Save and Deploy
Every push to main will auto-deploy.
# Build first
npm run build
# Install Wrangler CLI
npm install -g wrangler
# Login to Cloudflare
wrangler login
# Deploy
wrangler pages deploy dist --project-name=db-interview-prep- Run
npm run build - Go to Cloudflare Dashboard → Workers & Pages → Create
- Select Pages → Upload assets
- Drag the
dist/folder into the upload area - Deploy
- Vite — Fast build tool
- React 18 — UI library
- Outfit — Display font
- JetBrains Mono — Code font
- No external UI libraries — pure React with inline styles
MIT — use it however you want. Good luck with your interview! 🚀