Hi all,
I'm looking at making the right keys in our database model. I've been reading some topics on the forum but haven't found a shared opinion on the best practice.
- Super natural keys
- Advantage:
Easy to use.
- Disadvantage
Huge performance impact. According to some topics reloads can increase in time from 3 till 30 minutes.
Their are relations in reloading the tables in the correct sequence. TX will calculate this sequence, however their is an increased change of circle references.
- Advantage:
- Hashed Keys
- Advantage:
Easy to use.
Should be faster than SNK. It doesn't need a look up to the keystore. - Disadvantage:
Change on duplication of keyus is limited to a minimum Source: https://stackoverflow.com/questions/297960/hash-collision-what-are-the-chances
- Advantage:
- Look up DW_Id from different tables
- Advantage:
Able to make all joins on last layer.
Easy to use.
BIGINT in keys, is better than VARCHARS in keys. - Disadvantage:
It will cost the simple mode in transfering data from data area X to Y
- Advantage:
- Concat values (joining multiple columns together and don't hash)
- Advantage: …?
- Disadvantage:
VARCHAR in key instead of INT.
My personal preference is not to use the Super natural keys. It's taking, (in my opinion) to big of an impact on the performance of TX reloads. So in that case I would choose one of the other three other options. However I'm not sure which one is the best of all options. Hashed Keys seems doable, but I'm not sure of the impact of this method.
What do you think?