What is the difference between warehouse key and surrogate key?

Answer Posted / jaspreet banga

Surrogate key concept:- Surrogate keys are generated by
system and they identifies unique 'ENTITY'! yes its entity
and not record ,while primary key is used for finding
unique record.

Let me give you a simple classical example for surrogate
key:

On the 1st of January 2002 Employee 'E1' belongs to
Business Unit 'BU1' (that's what would be in your Employee
Dimension). This employee has a turnover allocated to him
on the Business Unit 'BU1' But on the 2nd of June the
Employee 'E1' is muted from Business Unit 'BU1' to Business
Unit 'BU2.' All the new turnover have to belong to the new
Business Unit 'BU2' but the old one should Belong to the
Business Unit 'BU1.'

If you used the natural business key 'E1' for your employee
within your datawarehouse everything would be allocated to
Business Unit 'BU2' even what actualy belongs to 'BU1.'

If you use surrogate keys you could create on the 2nd of
June a new record for the Employee 'E1' in your Employee
Dimension with a new surrogate key.

This way in your fact table you have your old data (before
2nd of June) with the SID of the Employee 'E1' 'BU1.' All
new data (after 2nd of June) would take the SID of the
employee 'E1' 'BU2.'

You could consider Slowly Changing Dimension as an
enlargement of your natural key: natural key of the
Employee was Employee Code 'E1' but for you it becomes
Employee Code Business Unit - 'E1' 'BU1' or 'E1' 'BU2.' But
the difference with the natural key enlargement process is
that you might not have all part of your new key within
your fact table so you might not be able to do the join on
the new enlarge key -> so you need another id.

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is meant by pre and post session shell command?

619


Debugger what are the modules, what are the options you can specify when using debugger, can you change the expression condition dynamically when the debugger is running.

1866


Why sorter is an active transformation?

744


Suppose we configure sorter transformations in the master and detail pipelines with the following sorted ports in order: item_no, item_name, price. When we configure the join condition, what are the guidelines we need to follow to maintain the sort order?

652


Is it possible to use a client with different version than that of its Informatica server?

641






What are active and passive transformations?

647


Tell me about Propagate functions in informatica

520


in reporting we add some new objects,how we get the count of the newly added objects to the report

1747


What is incremental aggregation?

570


Differentiate between a database and data warehouse?

650


Define sessions in informatica etl?

613


What does role playing dimension mean?

621


What is data transformation manager process?

619


generate date / time dimension in informatica

717


How to load a Dimension ? and how to load a fact table?

949