Answers were Sorted based on User's Feedback
The Surrogate Key Generator stage is a processing stage that generates surrogate key columns and maintains the key source. A surrogate key is a unique primary key that is not derived from the data that it represents, therefore changes to the data do not change the primary key.
How to generate surrogate key without using surrogate key stage?..
Answer / venkatesh.m
by using the transformer we can do it.To generate seqnum there is a formula by using the system variables ie [@partation num + (@inrow num -1) * @num partation
How to generate surrogate key without using surrogate key stage?..
Answer / murali
yes ur right but we have another way to generate s key by using transformer .in transformer we have a surrogate key tab click the skey tab in that we hav state file and db sequence these r used for generate and hold the s key value
How to generate surrogate key without using surrogate key stage?..
Answer / sudhir
Surrogatekey is nothing but a unique number to identify the
record in datamart. So just use a counter in StageVariable of Transformer. Keep incrementing the counter by one for every new inserts. This would form a surrogatekey.
How to generate surrogate key without using surrogate key stage?..
Answer / sreenu
Using the Routine KeyMgtGetNextVal KeyMgtGetNextValConn
How to generate surrogate key without using surrogate key stage?..
Peek Stage In Datastage
Answer / nish
Surrogate Key Generator Stage In Datastage 2![]()
sudhir your answer is wrong. just incrementing will not work in a multinode config. the answers that utilize the @partition num variable are correct
How to generate surrogate key without using surrogate key stage?..
Answer / snehasis
![]()
By using system variable in transformer stage like 1) create a stage var(SVK). 2) go to stage var. property type in the initial value tab as @partionnum - @numpartion+1 3) in the stage var. derivation type SVK+@numpartition Comments are closed.
|
AuthorWrite something about yourself. No need to be fancy, just an overview. Archives
December 2020
Categories |