Pages

Thursday, June 9, 2011

Locks in Database-2

Below is the query that can help you with multiple enqueue.

Wednesday, June 8, 2011

Locks in Database

Locks are mainly helpful to serialize jobs. Lock on a object is required by a session to update/edit the same, and if some other session wants to update it then it has to wait until earlier one releases the object and it comes to a consistent state.
This may be an object level enqueue to get the object edited by different sessions, or may be library lock/pin for the latch being used. But its dba who can decide what session should not be allowed to proceed or to be terminated taking others on priority.


Below are few of those tables and views that can help in identifying all kinds of locks