Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: LOCK STATEMENT
Please modify for your needs. Hope this helps you.
Query
acc.object object, ses.lockwait, txt.sql_text sqltext from v$sqltext txt, v$access acc, v$session ses, v$lock where txt.address = ses.sql_address
and txt.hash_value = ses.sql_hash_value and ses.sid = acc.sid and ses.lockwait is not null
Thanks
Leo
In article <3815F18C.311A112D_at_br.oracle.com>,
William de Souza Alencar <walencar_at_br.oracle.com> wrote:
> This is a multi-part message in MIME format.
> --------------F847BC986012CB99F6E97251
> Content-Type: text/plain; charset=iso-8859-1
> Content-Transfer-Encoding: 8bit
>
> Hi guys,
>
> I´m using ORACLE8 and I´d like to find out which SQL STATEMENT is
> locking a TABLE on database.
>
> Example, when some user instance "UPDATE EMP SET SAL = 10" a lock
will
> be generated into V$LOCK.
>
> How can I recover this statement from V$ TABLES ?
>
> Thanks in advance,
>
> WILL,
>
> --------------F847BC986012CB99F6E97251
> Content-Type: text/x-vcard; charset=us-ascii;
> name="walencar.vcf"
> Content-Transfer-Encoding: 7bit
> Content-Description: Card for William de Souza Alencar
> Content-Disposition: attachment;
> filename="walencar.vcf"
>
> begin:vcard
> n:Alencar;William
> tel;work:55 61 327-5151
> x-mozilla-html:TRUE
> org:ORACLE SUPPORT SERVICES;<img
src=http://www.geocities.com/TheTropics/3068/oraani.gif><br>
> adr:;;;;;;Brazil
> version:2.1
> email;internet:walencar_at_br.oracle.com
> title:Field Support Analyst
> fn:William de Souza Alencar
> end:vcard
>
> --------------F847BC986012CB99F6E97251--
>
>
Sent via Deja.com http://www.deja.com/
Before you buy.
Received on Tue Oct 26 1999 - 16:18:06 CDT