Re: Currently executing SQL statment
From: Alvin W. Law <alaw_at_us.oracle.com>
Date: 1995/09/05
Message-ID: <ALAW.95Sep5113615_at_ap283sun.us.oracle.com>#1/1
Date: 1995/09/05
Message-ID: <ALAW.95Sep5113615_at_ap283sun.us.oracle.com>#1/1
In article <423mr7$kcn_at_ixnews2.ix.netcom.com> posborn_at_ix.netcom.com (Paul Osborn) writes:
> Does anyone have the SQL code that will retrieve the currently
> executing SQL statment (I hope that makes sense). Some vendors of DB
> monitoring tools (Adhawk & DBVision) are demonstrating the ability to
> extract and display the currently executing SQL statement. My guess is
> that they are getting it from a V$ table in 7.1+.
select t.sql_text
from v$sqltext t, v$session s
where s.sql_address = t.address
and s.process = <client program pid>
order by t.piece;
-- "Everything that can be said about Win95 has been said... The Win95 user interface is not nearly as good as the Mac. Blah, blah. It has all been said a thousand times." - Larry Ellison Alvin W. Law ........................................... Oracle Corporation Senior Technology Consultant ............... 300 Oracle Parkway, Box 659305 Applications Design & Architecture ............... Redwood Shores, CA 94065 Email: alaw_at_oracle.com ...... Voice: +1.415.506.8317 . Fax: +1.415.506.7294Received on Tue Sep 05 1995 - 00:00:00 CEST