Issue with db2 update&Insert Statement

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
aladap12
Participant
Posts: 60
Joined: Fri Jul 20, 2007 1:15 pm
Location: NO

Issue with db2 update&Insert Statement

Post by aladap12 »

Hi,

I am loading data in db2 database using datastage.

In the process of loading I have two processing columns
add date, Modified date.

I am Using db2 stage to load data.

Job design is like \

Source -----> Tfm--------> Target.

Using update action : update existing or Insert New rows.

we are passing the values to adddate,modified date manually (hardcoded) in the transformer stage.

when I ran my job data is moving fine but for both update and Insert both date fields are populating

My requirement is I need pass both the date columns to Newly Inserted records only. For updated records I have to papulate only modified date .

Please suggest me how to achive this in datastage.

I appriciate your time and help.


Thanks
VKR
chulett
Charter Member
Charter Member
Posts: 43085
Joined: Tue Nov 12, 2002 4:34 pm
Location: Denver, CO

Post by chulett »

You can't use a "combo" action for that. You'll need to pre-qualify inserts v. updates using a lookup and then write out separate links for each with the proper data.
-craig

"You can never have too many knives" -- Logan Nine Fingers
Post Reply