cancel
Showing results for 
Search instead for 
Did you mean: 

Select for update query in sender JDBC

Former Member
0 Kudos

Hi All,

Can we write a Select for update query in the sender JDBC?

If yes, then if the select fails for some reasons for some rows, will the update happen only for the rows selected or for all the rows marked for select?

Please help!!

Thanks n Regards

Pushpinder Kaur

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Hi,

The Select statement failes then no data will be selecetd, if selcet Statement have selecetd any rows then only those filtered rows will be updated with Update Query. Others will not be cahnged.

In Update you can use inner statements with select

e.g. UPDATE table SET processed = (SELECT testFlag FROM table WHERE processed = 0;) WHERE processed = 0;

Thanks

swarup