Generating Surrogate key value

Post questions here relative to DataStage Server Edition for such areas as Server job design, DS Basic, Routines, Job Sequences, etc.

Moderators: chulett, rschirm, roy

Post Reply
maffan76
Participant
Posts: 110
Joined: Tue Aug 23, 2005 5:27 am

Generating Surrogate key value

Post by maffan76 »

Hi,
i have 2 tables and i have one intermediate table containing the incremental data and the other one is the main table. i want to assign the incremental value to all the rows in intermediate table starting from the maximum value of the target table.

whats the possible approaches and pros and cons?

Thanks in advance.
Regards,
Affan
"Questioning is Half Knowledge"
singhald
Participant
Posts: 180
Joined: Tue Aug 23, 2005 2:50 am
Location: Bangalore
Contact:

Post by singhald »

hi

using the SCD job u can create Surrogate key value to coloumn.

in this job u have to use a hash file as lookup and same file u will use for update the data.
u look up in to hash file based on incomming data from main file or load.

just create a stage varibale to generate surrogate key based on id coloumn.


singhal
Post Reply