Historization Type (Term and Relationship)
Applies to
Platform: Microsoft SQL Server · Snowflake · Databricks · Databricks dbt · Fabric Lakehouse · Fabric Warehouse · Oracle
Architecture: Data Store · Dimensional · Data Mart
Historization Type decides what a changed term value does to the stored versions: a new version, an overwrite or no change. Set it on every descriptive term of a Store Entity, Entity or Mart Dimension.
Data Vault and Stage objects have no Historization Type. Satellites keep a new version for every change of BG_RowHash.
Where to set it
Set the property when you edit a term. On an Entity, a relationship has a Historization Type too.
Values
SCD2: a changed value closes the current version and starts a new one.SCD1: a changed value overwrites the term in every version of the business key. It starts no version.SCD0: the value of the first version is kept, also when it is NULL and a later load delivers a value.
When any SCD2 term changes, the new version holds the current values of all SCD1 and SCD2 terms; SCD0 terms keep their first value. Change detection and historization explains how SCD0, SCD1 and SCD2 terms work together, with an example.
Defaults
A new term gets this Historization Type:
| Model object type | Default |
|---|---|
| Store Entity | SCD2 |
| Entity | SCD2 |
| Mart Dimension | SCD1 |
Only business keys and Default Terms stay empty. Any other term without SCD0, SCD1 or SCD2 fails validation with error ID-10008: Model object '<model object name>' of type '<type>' has unsupported historization type for terms defined. Supported historization types are: SCD0, SCD1, SCD2. On an Entity, a relationship without one fails with error ID-10009.
Effect on generated output
An object with at least one SCD2 term or relationship is historized. It gets BG_ValidFromTimestamp and BG_ValidToTimestamp. A closed version ends at the BG_ValidFromTimestamp of the next version. The current version ends at the End of Universe.
Related articles
- Reference: Delta Detection (Model Object), BG_ValidFromTimestamp, BG_ValidToTimestamp, Begin of Universe (Project), End of Universe (Project)
- See also: Change detection and historization, Edit a Term, Manage Historization Types