Back to glossary

Slowly Changing Dimension (SCD)

A data warehousing technique for tracking changes to dimension attributes over time, preserving historical context so that past facts can be analyzed against the dimension values that were current at that time.

Dimensions change: customers move cities, products change categories, employees change departments. Slowly changing dimensions handle these updates while preserving analytical accuracy. Without SCD, historical analysis would incorrectly attribute all past activity to the current dimension values, distorting trends and comparisons.

The most common types are SCD Type 1 (overwrite the old value, losing history), Type 2 (add a new row with effective dates, preserving full history), and Type 3 (add a column for the previous value, tracking one level of history). Type 2 is most common in practice because it preserves complete history while enabling both current and historical analysis.

For AI teams, SCD Type 2 is essential for building point-in-time correct training data. A churn prediction model must use the customer's attributes as they were at the time of the prediction, not their current attributes. Without proper SCD handling, training data would contain future information (data leakage), inflating apparent model performance and degrading real-world accuracy.

Related Terms