Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

locking strategy on deletes

Status
Not open for further replies.

blom0344

Technical User
Mar 20, 2002
3,441
NL
How does ORACLE work with regards to deleting a set of records from a table? Does it lock the entire table , avoiding inserts untill the commit is issued (on the delete statement) Can the table still be accessed for read-only action during the delete action?

Ties Blom

 
Oracle handles DELETE like it does INSERT and UPDATE. Only row-level locks are issued; the other rows in the table are still available for UPDATE/DELETE, and INSERTs can also be executed simultaneously.
In addition, the deleted rows are available to SELECT statements until the COMMIT is issued.
 
Until the delete is committed, the original records are available for any other user to read. As soon as the commit is done, the rows are gone. Any new inserts or updates (except on the deleted records are allowed before, during, or after the commit. For a full description see:


Bill
Oracle DBA/Developer
New York State, USA
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top