InterviewStack.io LogoInterviewStack.io

Database Fundamentals and Data Modeling Questions

Encompasses foundational database concepts and techniques for designing and querying data stores. Topics include relational database concepts, structured query language fundamentals for selecting and modifying data, schema design with tables and relationships, normalization principles, entity relationship modeling, indexing and basic performance considerations, transactions and data integrity, constraints and data types, and common operational tasks such as migrations, backups, and simple optimization strategies. Also discusses trade offs with nonrelational stores and when to choose different persistence models.

MediumSystem Design
35 practiced
Design a relational schema for an e-commerce order system supporting multiple addresses per user, multiple payment methods, order items, product catalog with categories, soft deletes, and order auditing. Assume 10M users and 200M orders/year; describe tables, primary/foreign keys, partitioning strategy, and indexing choices to support both reads and writes.
EasyTechnical
30 practiced
Describe common backup strategies for relational databases: full backups, incremental/differential backups, and point-in-time recovery (PITR). Explain pros/cons and the typical recovery steps for each strategy when dealing with accidental data deletion or corruption.
HardTechnical
38 practiced
Explain the CAP theorem in the context of distributed databases. For a global social media timeline service, analyze design choices you would make under network partitions (favor consistency vs availability) and describe user experience trade-offs for each choice.
HardTechnical
35 practiced
Compare two-phase commit (2PC) and the Saga pattern for managing distributed transactions across microservices and independent databases. For each approach describe failure modes, compensating action design, performance implications, and when you would prefer one over the other.
HardTechnical
34 practiced
Production is showing an increasing frequency of deadlocks between two tables during nightly batch jobs. Describe how you would diagnose the root cause using DB diagnostics and logs, how to reproduce and test in staging, short-term mitigations to stop the incident, and long-term fixes including transaction redesign or indexing improvements.

Unlock Full Question Bank

Get access to hundreds of Database Fundamentals and Data Modeling interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.