Update and Insert on the Same Table

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
bapajju
Participant
Posts: 82
Joined: Wed Nov 19, 2003 11:58 pm

Update and Insert on the Same Table

Post by bapajju »

Hello,

I have a typical problem. My target is a Teradata Table. I have to Update the Existing records for sertain field and Insert New record for the Corresponding updated record.

In Teradata for Update and Insert link if I put Transaction size more than 1 then the Table gets locked. So the only option is to put transaction size as 1 for Update and Insert link. But this process takes longer time load large amount of data as Transaction size is set to 1.

Is there any simple way that I can Insert and Update multiple rows into Teradat table with More than One Transaction Size.

Thanks
Bapajju
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

Do the inserts and the updates separately. Use a lookup to determine whether the row already exists; choose one of two output links on this basis.
You might even consider directing these links to text files ready for bulk loading into the table.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
bapajju
Participant
Posts: 82
Joined: Wed Nov 19, 2003 11:58 pm

Post by bapajju »

Thanks Ray. That's a great idea.
ray.wurlod wrote:Do the inserts and the updates separately. Use a lookup to determine whether the row already exists; choose one of two output links on this basis.
You might even consider directing these links to text files ready for bulk loading into the table.
Post Reply