Using lock table, PL-SQL Programming


You use the LOCK TABLE statement to lock the whole database tables in the specified lock mode so that you can share or deny the access to them. For illustration, the statement below locks the emp table in the row share mode. The Row share locks permit concurrent access to the table; they avoid other users from locking the whole table for the restricted use. The Table locks are released when your transaction issues a commit or rollback.


The lock mode determines what other locks can be located on the table. For illustration, many users can obtain the row share locks on the table at the same time, excluding only one user at a time can obtain an exclusive lock. Whereas one user has an exclusive lock on the table, no other users can insert, delete, and update rows in that table.

Posted Date: 10/4/2012 5:21:05 AM | Location : United States

Related Discussions:- Using lock table, Assignment Help, Ask Question on Using lock table, Get Answer, Expert's Help, Using lock table Discussions

Write discussion on Using lock table
Your posts are moderated
Related Questions
Using EXTEND To enlarge the size of a collection, use EXTEND. This process has 3 forms. The EXTEND appends one null element to a collection. And the EXTEND(n) appends n null e

Declaring Objects: You can use the object types wherever built-in types like CHAR or NUMBER can be used. In the block below, you can declare object r of type Rational. Then, yo

Closest Approximation to Relational Union - SQL Actually, just as SQL has several varieties of JOIN, it also has several varieties of UNION, none of which is equivalent to th

LAWS / RULES - Dollo's Law                     :           Living organisms do exhibit evolutionary irreversibility or evolution is irreversible. Williston's Law

Using EXISTS The EXISTS(n) returns TRUE if the nth element in a collection exist. Or else, EXISTS(n) returns FALSE. Primarily, you use EXISTS with DELETE to maintain the spars

Using LIMIT For nested tables, that have no maximum size, the LIMIT returns NULL. For varrays, the LIMIT returns the maximum number of elements that a varray can have (that yo

Updating Objects: To change the attributes of objects in an object table, you can use the UPDATE statement, as the illustration below shows: BEGIN UPDATE persons p SET p

Delimiters A delimiter is a simple or compound symbol which has a special meaning to PL/SQL. For example, you use delimiters to symbolize an arithmetic operation like additio

Based on the EMPLOYEE table created in Assignment #1, write a PL/SQL anonymous block that accepts an employee ID from the user input and finds whether the employee ID is in the EMP

Closing a Cursor The CLOSE statements disable the cursor, and the result set becomes undefined. An illustration of the CLOSE statement as shown: CLOSE c1;