Skip to content
January 24, 2011 / doganay

HOW TO FIND PROCEDURE BLOCKING SESSIONS (ALSO FUNCTION, PACKAGE, TRIGGER, CLASS BLOCKING SESSIONS)

, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , ,
select
decode(o.kglobtyp,
7, 'PROCEDURE',
8, 'FUNCTION',
9, 'PACKAGE',
12, 'TRIGGER',
13, 'CLASS'
) "TYPE",
o.kglnaown "OWNER",
o.kglnaobj "NAME",
s.indx "SID",
s.ksuseser "SERIAL",
s.ksuudnam "USERNAME",
s.ksuseapp "PROGRAM",
x.app "MODULE",
x.act "ACTION",
x.clinfo "CLIENT_INFO"
from
sys.x$kglob o,
sys.x$kglpn p,
sys.x$ksuse s,
sys.x$ksusex x
where
o.inst_id = userenv('Instance') and
p.inst_id = userenv('Instance') and
s.inst_id = userenv('Instance') and
x.inst_id = userenv('Instance') and
p.kglpnhdl = o.kglhdadr and
s.addr = p.kglpnses and
s.indx = x.sid and
s.ksuseser = x.serial and
o.kglhdpmd = 2 and
o.kglobtyp in (7, 8, 9, 12, 13)
order by 1,2,3;
/
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: