Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
prasanthkesana
Contributor
Contributor

How to run db2 update query using talend job

Hi All,

I am able to read data from file but got stuck to update data into the table.

I would like to run db2 update query using talend component.

Please help me to provide any suggestion to achieve this.

Below is the update query:

UPDATE table

   SET

    column1 = inputvalu1 ,

    column2 = :inputvalu2,

    column3 = :inputvalu3,

    column4 = :inputvalu4

   WHERE

    column0         = :inputvalu0 AND

    column1 = ( SELECT MAX(column1) FROM table  

               WHERE column0 = : inputvalu0);

Note: above query should work with dynamic input values

please suggest job work flow.

Thanks,

Prasanth

Labels (2)
2 Replies
Anonymous
Not applicable

prasanthkesana
Contributor
Contributor
Author

Hello

I have referred the above links, and prepared update query as per my requirement but after executing the query values are not updating in db2 table.

my job work flow is

tdbconncetion open-->

tfileinput--> tinputfiledelimited-->tmap-->tjavarow-->tdbrow-->tdbcommit-->tdbclose

 

The job gets hang when it reaches to tdbrow, without throwing any error.

please suggest any other alternative solution to run update query instead of tdbrow.

 

Thanks,

Prasanth