Quantcast
Channel: SQL Server Data Warehousing forum
Viewing all articles
Browse latest Browse all 1203

type 1 and type 2 slowly change dimension

$
0
0

I am new to data warehousing

3 questions regarding SCD type 1 and 2.

1.

In type 1 SCD, what's the best practice to load dimensions? Do I have to insert new and update existing based on natural key? Or can I just truncate dimension table then do a full load?

2. In type 2 SCD, if I understand correctly, there can be more than one records with the same natural key with different surrogate keys? Then when you load the facts, how to decide what dimension surrogate key to lookup? Is it to pick up the latest record (same natural key with maximum surrogate key, or same natural key with end date is null if there is a end date implemented on the dimension table)?

3. In type 2 SCD, there can be more than one records with the same natural key with different surrogate keys. Then these records are treated as different dimension members. So in SSAS, dimension design, these will appear to be different members but with probably same name.

E.g.

surrogate1, customer1, property1, enddate1

surrogate2, customer1, property2, enddate2

surrogate3, customer1, property3, null

These will be three different member in customer dimension,but looks the same to end user because all customer1. Is this ok?

Thanks


Viewing all articles
Browse latest Browse all 1203

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>