Update then Insert : Insert not Working in ODBC Enterpeise

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
swades
Premium Member
Premium Member
Posts: 323
Joined: Mon Dec 04, 2006 11:52 pm

Update then Insert : Insert not Working in ODBC Enterpeise

Post by swades »

Hi,

I am doing Upsert: Update then Insert to DB2 Table using ODBC Enterprise Stage. I am using Userdefined query.

Update working fine but Insert is not working. In log No Error Massage,No warning.

Only insert AND only update works fine with same query

If any one come across this type of issue then please advise to resolve this.

Thanks.
us1aslam1us
Charter Member
Charter Member
Posts: 822
Joined: Sat Sep 17, 2005 5:25 pm
Location: USA

Post by us1aslam1us »

If Insert and update are working fine then why not work with them instead of upsert. I guess both will give you same result. Something like this :

Code: Select all

 
                           
                             insert 
                           ---------> 
   -->    Transformer stage          ODBC Enterprise stage 
                           ---------> 
                            update
I haven't failed, I've found 10,000 ways that don't work.
Thomas Alva Edison(1847-1931)
swades
Premium Member
Premium Member
Posts: 323
Joined: Mon Dec 04, 2006 11:52 pm

Post by swades »

Thanks for reply

But In DS 7.5.2 EE : cant have 2 input links towards a single ODBC Enterprise Stage.

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

Post by ray.wurlod »

No problem. Use two ODBC Enterprise stages, one on each link.
IBM Software Services Group
Any contribution to this forum is my own opinion and does not necessarily reflect any position that IBM may hold.
swades
Premium Member
Premium Member
Posts: 323
Joined: Mon Dec 04, 2006 11:52 pm

Post by swades »

Thanks

But how can I assure that It will do 1st Update and then Insert. I tried by giving link order but somtimes that is not working.

Thanks
novneet
Participant
Posts: 28
Joined: Tue Jan 17, 2006 2:19 pm
Location: PUNE(INDIA)

Post by novneet »

Why don't u use the DB2 enterprise stage.
Regards,
Novneet Jain
DSguru2B
Charter Member
Charter Member
Posts: 6854
Joined: Wed Feb 09, 2005 3:44 pm
Location: Houston, TX

Post by DSguru2B »

You can make sure of that via link ordering. But that will only happen for a 'per row' basis. If you want all inserts first and then all updates or vice versa for that matter, do it in seperate jobs.
Creativity is allowing yourself to make mistakes. Art is knowing which ones to keep.
Post Reply