InterviewStack.io LogoInterviewStack.io

Data Modeling and Schema Design Questions

Focuses on designing efficient, maintainable data schemas for transactional and analytical systems. Candidates should demonstrate understanding of normalization principles and normal forms, when and why to denormalize for performance, and schema design patterns for different use cases. Expect dimensional modeling topics including fact and dimension tables, star and snowflake schemas, grain definition, slowly changing dimensions, and strategies for handling historical data. The topic also includes trade offs between online transaction processing and online analytical processing designs, query performance considerations, indexing and partitioning strategies, and the ability to evaluate and improve existing schemas to meet business requirements and scale.

HardTechnical
58 practiced
A streaming ingestion pipeline writes into a delta/iceberg table with append-only commits. Describe an efficient strategy to implement deduplication and idempotent upserts at scale, given that events may be duplicated in the stream and arrive out-of-order. Include discussion of keys, compaction, and impact on partitioning.
EasyTechnical
34 practiced
What does 'grain' mean in dimensional modeling? Given a Sales fact table, list three possible grain choices (e.g., per-order-line, per-invoice, per-day-per-product) and explain the implications of each choice for aggregation, joins to dimensions, deduplication and ETL complexity.
HardTechnical
31 practiced
Your analytics workload requires per-day per-product sales metrics and also the ability to reconstruct historical daily cohorts quickly. Propose a schema and storage layout for daily snapshots that balance storage cost with query speed and support efficient point-in-time queries. Describe how to store deltas vs whole-day snapshots and how to rebuild a historical snapshot for a given date.
MediumTechnical
56 practiced
Provide a step-by-step approach to evaluate and improve an index strategy on a production database with frequent schema changes. Include how you'd collect evidence, prioritize indexes, and safely deploy index changes.
MediumTechnical
41 practiced
You have a fact table that is heavily used for aggregations by customer and product. Query profiling shows many slow GROUP BY queries. Propose schema-level and physical-design changes to speed up aggregation queries without significantly increasing write latency.

Unlock Full Question Bank

Get access to hundreds of Data Modeling and Schema Design interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.