How to delete & update records from DB2 API Stage?

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
iamnagus
Participant
Posts: 48
Joined: Wed Sep 29, 2004 1:16 am

How to delete & update records from DB2 API Stage?

Post by iamnagus »

Hi,

I need to delete or update a record from DB2 table.
My job design is like this.

DB2 API stage--------->Transformer-------->DB2 API Stage
(To read the table) (To assign a value (To update or Delete)
Into stage variable)

Qurey(in Second API Stage):
'DELETE FROM raoridbf.model WHERE (raoridbf.model.CODE=ORCHESTRATE.CODE)

Here is issue with this code:

"CopyOfModel1_job..DB2_UDB_API_6: [IBM][CLI Driver][AS] SQL5001N "CODE" does not have the authority to change the database manager configuration file. SQLSTATE=42703

SQLExecDirect: Error executing statement 'DELETE FROM raoridbf.model WHERE (raoridbf.model.CODE=ORCHESTRATE.CODE)'. See following DB2 message for details."

Please suggest me to where i am doing wrong. Please explain in what stage whats need to be done.

Even my design is wrong, please advice me for correct design.


Thanks & Regards,
iamnagus
Kirtikumar
Participant
Posts: 437
Joined: Fri Oct 15, 2004 6:13 am
Location: Pune, India

Post by Kirtikumar »

What is the job type?

The one mentioned in your post is server.
Regards,
S. Kirtikumar.
vicmania
Participant
Posts: 7
Joined: Tue Sep 12, 2006 10:47 am

Re: How to delete & update records from DB2 API Stage?

Post by vicmania »

Hello,

try to execute the same sql with the same user from a DB2 client directly. I assume you have a problem with the user - not the correct rights on the database ...

Rgds Vicmania
iamnagus
Participant
Posts: 48
Joined: Wed Sep 29, 2004 1:16 am

Post by iamnagus »

Hi,

The same query is able execute in the DB2 Client database. I am getting this issue from datastage.

Regards,
iamnagus
Post Reply