Is it possible to update a CURSOR in which we have used JOIN on 2 tables ORDERS and TRANSACTIONS? Why or Why not? How can we proceed to UPDATE any of these tables?

DB2DatabaseBig Data Analytics

When we use JOIN on one (self join) or more table inside a cursor declaration then a read-only cursor will be created. We cannot update the read-only cursor.

If we want to update any of the tables used in the JOIN then we have to declare a separate cursor for all the tables and an individual logic has to be built in order to update each DB2 table.

Updated on 15-Sep-2020 10:47:15