Updating two different tables with cursor oracle Dirty web chat bot
The prudent use of temporary tables can dramatically improve Oracle SQL performance.
To illustrate the concept, consider the following example from the DBA world.
It is important not to allow one operation to succeed while the other fails.
Oracle doesn't know if it did—Oracle doesn't keep track. If that cursor remained open, it could well see records that don't, didn't, and won't ever exist.
So, the rollback to savepoint would have wiped out records that your cursor in theory should and would be able to see. The general rule is: any rollback to a savepoint that happened before the open of the cursor will cause this error.
At the end of a transaction that makes database changes, the database makes all the changes permanent or undoes them all.
If your program fails in the middle of a transaction, the database detects the error and rolls back the transaction, restoring the database to its former state. However, there are limitations on the use of pseudocolumns, including the restriction on the use of some pseudocolumns in assignments or conditional tests.