Hello
I need to execute many DML-Operations on a table but I want to lock the table for external sessions during this interaction.
Problem: I want to execute COMMITs too.
How can I do this?
1.) LOCK TABLE or set it READ ONLY BUT only for other sessions
2.) UPDATE table -> COMMIT and more UPDATE/INSERT etc. COMMIT
3.) UNLOCK TABLE or set it back to READ WRITE
Problem:
If I use the LOCK TABLE IN EXCLUSIVE MODE or other Modes a COMMIT releases the lock
If I use the ALTER TABLE ... SET READ ONLY -> then I can not update the rows any more in my own session.
How can I prevent other DMLs from other sessions on my table during DML processings?
Thank you all for your help,
Regards, Hans