State the grain of a fact table before selecting facts or dimensions.
Grain is the row-level promise. Start with the business event A fact table begins with a process, not with a list of available columns. Order placed, shipment delivered, support ticket closed, subscription renewed: each of these can be modeled, but each has a different natural row. Grain names that row precisely. Facts only make sense at a declared grain Revenue, quantity, cost, and duration are only valid when you know what they attach to. Header-level revenue placed onto line-level rows will multiply. Line-level discount placed onto invoice rows will disappear. Grain protects arithmetic before arithmetic starts. Dimensions follow the grain…
Sign up free — one personalized lesson every day, matched to your role and goals.
Already have an account? Sign in