Loading and Deleting in a Single Unit of Work

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
ag_ram
Premium Member
Premium Member
Posts: 524
Joined: Wed Feb 28, 2007 3:51 am

Loading and Deleting in a Single Unit of Work

Post by ag_ram »

Hi Folks

Is it possible to load data into an oracle table and delete some records based on a certain condition on the same table , and maintain these as a single Unit of work ?
DSguru2B
Charter Member
Charter Member
Posts: 6854
Joined: Wed Feb 09, 2005 3:44 pm
Location: Houston, TX

Post by DSguru2B »

Sure. You can pass the delete command in the OPEN/CLOSE option of the enterprise stage and do your regular operation of load or upsert.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
ag_ram
Premium Member
Premium Member
Posts: 524
Joined: Wed Feb 28, 2007 3:51 am

Post by ag_ram »

Hi

When Oracle Enterprise is used as a Target Stage we dont have that option of open/close command..Correct me if iam wrong
Govindarajan
Participant
Posts: 24
Joined: Mon Jul 12, 2004 10:16 am

Re: Loading and Deleting in a Single Unit of Work

Post by Govindarajan »

ag_ram wrote:Hi Folks

Is it possible to load data into an oracle table and delete some records based on a certain condition on the same table , and maintain these as a single Unit of work ?
You can create userdefined SQL and place inside the After tab page. This will work.
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

What's in a name? Close in some stages, After in others.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
ag_ram
Premium Member
Premium Member
Posts: 524
Joined: Wed Feb 28, 2007 3:51 am

Re: Loading and Deleting in a Single Unit of Work

Post by ag_ram »

Govindarajan wrote:
ag_ram wrote:Hi Folks

Is it possible to load data into an oracle table and delete some records based on a certain condition on the same table , and maintain these as a single Unit of work ?
You can create userdefined SQL and place inside the After tab page. This will work.
There is no before and After Tab in a prallel Oracle Enterprise stage !
ray.wurlod
Participant
Posts: 54607
Joined: Wed Oct 23, 2002 10:52 pm
Location: Sydney, Australia
Contact:

Post by ray.wurlod »

There's no tab, but there IS an available property to add.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
ag_ram
Premium Member
Premium Member
Posts: 524
Joined: Wed Feb 28, 2007 3:51 am

Post by ag_ram »

Hi

The OPEN/CLOSE is indeed available , and we used the same in solving the problem. It is available with Load/Append mode in Oracle Enterprise , but is not available for use with UPSERT mode.

Sorry for the confusion !
Post Reply