Design a marketing schema your warehouse won't choke on
The modeling checklist before you load a single row.
1 — Separate raw, staging, and mart layers as distinct schemas.
Why: querying raw tables directly is how a dashboard refresh takes 40 minutes.
2 — Pick one grain per fact table and never mix granularities.
Why: a table that's half session-level and half user-level double-counts everything.
3 — Surrogate-key your dimensions instead of joining on email strings.
Why: string joins are slow and break the moment a casing changes.
4 — Materialize the marts marketing queries daily; leave the rest as views.
Why: you pay compute for what's materialized, so only materialize what's hot.
5 — Document each mart's owner in the model file.
Why: an unowned table is a table nobody dares change.
That's the stack for this week. Forward to a teammate.
Stack Curator
@StackCurator
Design a marketing schema your warehouse won't choke on
Этот пост опубликован в Telegram-канале Stack Curator. Подписаться можно по ссылке: @StackCurator.