"What Is the Grain of This Table?"
Concepts covered: dmGrainDefinition
Grain is not a modeling step. It is THE modeling step. Everything else follows from it: which columns belong in the table, which joins are valid, which aggregations produce correct numbers. Getting grain wrong does not produce an error message. It produces wrong numbers that look right. That is why interviewers test it. What They're Really Testing The 60-Second Framework Step 3 is the strong-hire signal. Asking the interviewer a clarifying question about grain shows you have been burned by wrong assumptions in production. Junior candidates never ask. Senior candidates always do. Grain Statements: Good vs Bad Why Companies Care Cite these in your answer: At Meta, wrong-grain caused ad revenue to be double-counted across ad groups for a quarter. At Amazon, order-level grain instead of item-l
About This Interactive Section
This section is part of the Grain and Fan Traps: Advanced lesson on DataDriven, a free data engineering interview prep platform. Each section includes explanations, worked examples, and hands-on code challenges that execute in real time. SQL queries run against a live database. Python runs in a sandboxed Docker container. Data modeling problems validate against interactive schema canvases. All content is framed around what data engineering interviewers actually test at companies like Meta, Google, Amazon, Netflix, Stripe, and Databricks.
How DataDriven Lessons Work
DataDriven combines four interview rounds (SQL, Python, Data Modeling, Pipeline Architecture) with adaptive difficulty and spaced repetition. Easy problems get harder as you improve. Weak concepts resurface until you master them. Your readiness score tracks progress across every topic interviewers test. Every lesson section ends with problems you solve by writing and running real code, not by picking multiple-choice answers.