This is from Steve Adam's Oracle 8i Internal Services(page 50-51)

Library cache locks are held in shared mode during parse operation.

A pin is applied to the library cache object for a PL/SQL program unit
or SQL statement while it is being compiled, parsed or executed. Pins
are normally held in shared mode, but are also held in execlusive mode
while the library cache information for the object is being changed.

So my understanding is that, locks are applied during parse etc
and pins during library cache information change.

Hope this is correct.

Shakir


--- Walter K <[EMAIL PROTECTED]> wrote:
> Perhaps this is a rudimentary question but I haven't 
> found any good info on this topic. Would someone 
> please explain the difference between a library cache 
> lock and a library cache pin? 
> 
> Is the first simply a dictionary lock on a physical 
> object (i.e. table) whereas the second is a dictionary 
> lock on a piece of code (i.e. procedure, function, 
> trigger)?
> 
> According to what I've read, I can query x$kgllk where 
> kgllkreq=0 to find the library object locks in the 
> database. How do I know if the lock is a library cache 
> lock vs. a library cache pin, simply by inference due 
> to the type of object?
> 
> If I perform a systemstate dump and see 'mode=S' under 
> a process, does that mean that the process has 
> a 'share' lock on the object? If so, I'm confused as 
> to why I don't see a corresponding lock in v$lock.
> 
> Any info would be appreciated. Thanks VERY much in 
> advance.
> 
> -Walt
> 
> -- 
> Please see the official ORACLE-L FAQ: http://www.orafaq.com
> -- 
> Author: Walter K
>   INET: [EMAIL PROTECTED]
> 
> Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
> San Diego, California        -- Mailing list and web hosting services
> ---------------------------------------------------------------------
> To REMOVE yourself from this mailing list, send an E-Mail message
> to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
> the message BODY, include a line containing: UNSUB ORACLE-L
> (or the name of mailing list you want to be removed from).  You may
> also send the HELP command for other information (like subscribing).


=====
Mohammed Shakir
CompuSoft, Inc.
11 Heather Way
East Brunswick, NJ 08816-2825
(732) 672-0464 (Cell)
(732) 257-6001 (Home)

__________________________________________________
Do you Yahoo!?
New DSL Internet Access from SBC & Yahoo!
http://sbc.yahoo.com
-- 
Please see the official ORACLE-L FAQ: http://www.orafaq.com
-- 
Author: Mohammed Shakir
  INET: [EMAIL PROTECTED]

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message
to: [EMAIL PROTECTED] (note EXACT spelling of 'ListGuru') and in
the message BODY, include a line containing: UNSUB ORACLE-L
(or the name of mailing list you want to be removed from).  You may
also send the HELP command for other information (like subscribing).

Reply via email to