regarding surrogate key generator

Post questions here relative to DataStage Enterprise/PX Edition for such areas as Parallel job design, Parallel datasets, BuildOps, Wrappers, etc.

Moderators: chulett, rschirm, roy

Post Reply
vmcburney
Participant
Posts: 3593
Joined: Thu Jan 23, 2003 5:25 pm
Location: Australia, Melbourne
Contact:

Post by vmcburney »

Reading about it in the Parallel Job Developers Guide may be faster then asking about it on this forum.
The stage generates sequentially incrementing unique integers from a given starting point. The existing columns of the data set are passed straight through the stage.
If the stage is operating in parallel each instance will increment by the number of partitions to ensure the numbering is unique. You can duplicate this functionality in a transformer by creating a counter set to @partitionnum - @numpartitions and incrementing it by @numpartitions. I would go for the specialist key generator stage unless you already have a transformer in your job.
richdhan
Premium Member
Premium Member
Posts: 364
Joined: Thu Feb 12, 2004 12:24 am

Post by richdhan »

Searching the forum will yield faster results on different methodologies used for generating sakeys.

We use the column generator, the transformer and the DB stage to generate surrogate keys. Pls search the forum.

HTH
Rich
Post Reply