Unanswered: Trying an update with data from an external table
I am trying to update a table with data from a SELECT...WHERE EXISTS that involves an external table and a second join to the table being updated. However, when it gets to the commit, an ORA-02051 ("another session or branch in same transaction failed or finalized") exception gets thrown.
Here's the code:
UPDATE the_table t
SET obs_fg = 1
FROM the_table t2
JOIN the_external_table@the_db_link ext
ON ext.key = t2.key
WHERE ext.old_key = t.key
What I end up doing is, I have to create an associative array of VARCHAR2, selecting the the_table.key values into that, and then looping through the array and updating the_table one key value at a time - and even that throws the same exception unless I add a commit between the select and the loop.
Both of the databases involved are 126.96.36.199.0.
Is there a way I can get the single update to work?
Is this a known bug of some sort? Apparently, it is - #9130054
Last edited by That Don Guy; 10-25-11 at 13:59.
Reason: Added bug number