Quick Search:
 
 The Oracle EXCLUSIVE Keyword      [Return To Index] Jump to:  

Term: EXCLUSIVE

Definition:
The Oracle PL/SQL EXCLUSIVE keyword defines one of the locking modes of a table. A table can be explicitly locked using LOCK TABLE command in two modes namely, EXCLUSIVE and SHARE mode. Note that this lock takes the preference over automatic locking.

An EXCLUSIVE lock mode prevents the associated resource from being shared. This lock mode is typically obtained to modify data. The first transaction to lock a resource exclusively is the only transaction that is allowed to alter the locked resource until the exclusive lock is released.

Example Usage:

The LOCK TABLE below statement locks the ORDERS table in exclusive mode. Note that due to the use of the NOWAIT parameter it does not wait if it has been already locked by another user.

LOCK TABLE ORDERS
IN EXCLUSIVE MODE
NOWAIT;


Related Links:
 
   Home |    Search |    Code Library |    Sponsors |    Privacy |    Terms of Use |    Contact Us © 2003 - 2024 psoug.org