Subject: Re: Help on how to get decode the resource id
References: <5kmg57$> () writes:

>Hello everyone,

>Can anyone tell me as how to get the exact resource from the v$lock
>using id1 and id2. I read somewhere that id1 will help in fetching 
>the object from the all_objects. 
>My question is how do i get a particluar record that is being locked
>by a particular process when o see the id1, id2. does id1, id2 point to
>a table/row or can it be any other resource.
>Thanks a lot in advance .
>Lakshmi Prasad


For the most part, id1 relates to the internal Oracle ID for an object. To
find out what it is, you can enter:

select * from dba_objects where object_id = xxxx;

Be sure to replace "xxxx" with the value of id1.

This works in many cases, including row-exclusive and table-exclusive locks.
Other locks are more internal latches, which is beyond the scope of this
response. The "Concepts" manual provides for a good background.

The above select statement will work in the majority of times, though.

-Ari Kaplan
Independent Oracle DBA Consultant

<-> For 60+ technical tips, visit my Web Page:                    <->
<->                                                               <->
<->                                    <->
<->                                                               <->
<->             email:                    <->

Back to Ari Kaplan's Home Page tm">Back to Ari Kaplan's Home Page