When designing your data warehouse, there is one constant you need to keep in mind: data changes. For example, a customer will update their shipping address, a product gets re-categorised, or an employee changes departments.
How to handle these updates determines both the accuracy of your historical reporting and the complexity of workflows that feed them. In data warehousing, strategies for handling these changes are known as Slowly Changing Dimensions (SCD).
There are several types of SCD, this blog will outline the most common ones alongside the implications of each for data pipelines, storage, and downstream analytics.
What is a Slowly Changing Dimension?
A Dimension in a data warehouse gives context to quantitative facts (e.g., sales, clicks, logs). Unlike fast-moving event tables, most dimensions change relatively infrequently, hence the "slowly changing."
Ultimately, choosing an SCD strategy comes down to answering one question:
When an attribute in a dimension changes, do you need to preserve the historical state, or do you only care about the current state?
[ Source Data Changes ]
│
┌───────────────────────────┼───────────────────────────┐
▼ ▼ ▼
[ Ignore Updates ] [ Overwrite Data ] [ Track History ]
│ │ │
Type 0 Type 1 ┌───────────┼───────────┐
(Retain Original) (No History) ▼ ▼ ▼
Type 2 Type 3 Type 4
(New Rows) (New Cols) (Audit Table)
Decision tree for the different behaviours of SCDs
Core Types of Slowly Changing Dimensions
1. Type 0: Retain Original (Fixed)
- How it works: Once data is written, it never changes. Any incoming updates for that record are ignored.
- Best for: Attributes that should naturally remain constant, such as a customer's original sign-up date, birth date, or initial order timestamp.
- Pros: Immutable, very simple to setup and manage unchanging dimensions.
- Cons: Challenging to manage corrections or changes in the data without manual intervention.
2. Type 1: Overwrite
- How it works: The new data overwrites the old data in place. No historical record is preserved.
- Best for: Correcting data entry errors or tracking attributes where history holds no analytical value (e.g., fixing a misspelled name or phone number).
- Pros: Simplest to build and query while keeping table sizes minimal, as records always reflect the most current state without expanding row counts.
- Cons: Completely destroys point-in-time historical context.
3. Type 2: Add New Row (Full History)
- How it works: A new row is inserted into the dimension table whenever a change occurs. Each record includes metadata like
valid_from,valid_to, and optionally anis_currentflag. - Best for: Core business entity tracking (e.g., customer address, plan tier, sales region) where accurate point-in-time reporting is mandatory.
- Pros: Complete auditability, all changes are preserved for any future requirements.
- Cons: Increases table row counts and therefore storage costs. Can require more complicated date filter logic in queries.
4. Type 3: Add New Column (Current vs. Previous)
- How it works: Instead of adding a new row, a new column is added to track the previous value alongside the current value (e.g.,
current_regionandprevious_region). - Best for: Tracking a single, limited step of history (e.g., seeing how sales performed under the current region vs. the immediately prior region).
- Pros: Low storage footprint, easy to query immediate history for any rows in the data.
- Cons: Limits level of history that can be stored to number of columns used (typically just one).
5. Type 4: History Table
- Type 4 (History Table): Keeps current records in a primary table and dumps all historical state changes into a separate history/audit table.
- Best for: High-volume dimensions with rapidly changing attributes (e.g., credit scores, income tiers, or customer status flags) where tracking full history in a single table causes massive bloat.
- Pros: Keeps primary dimension table lightweight for efficient queries.
- Cons: Increased complexity, requires dual table updates and multiple joins when comparing history to current
Quick Reference Summary
| SCD Type | History Kept? | Pipeline Complexity | Storage Growth | Primary Use Case |
| Type 0 | Static | Low | None | Immutable facts (e.g., Birth Date) |
| Type 1 | None | Low | None | Error corrections, irrelevant history |
| Type 2 | Full | High | High (Row bloat) | Historical auditing & point-in-time analysis |
| Type 3 | Soft (1 version) | Medium | Low | Immediate prior state comparison |
| Type 4 | Full (Separate) | Medium | High | Decoupling active data from audit logs |
- Use Type 0 when data is immutable
- Default to Type 1 when historical tracking is not required.
- Implement Type 2 selectively on key dimension attributes that drive financial, sales, or regulatory reporting, be wary of row bloat if full history is not required.
- Apply Type 3 if you only need a limited slice of history.
- Consider Type 4 if you want fast operational queries on active data without sacrificing an immutable historical audit log.

