Skip to content

Commit fbd381b

Browse files
committed
Shows the object causing the waits
1 parent 76fdb72 commit fbd381b

File tree

1 file changed

+28
-0
lines changed

1 file changed

+28
-0
lines changed

dbfile_seqread_object.sql

+28
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
REM Filename : dbfile_seqread_object.sql
2+
REM Author : Craig Richards
3+
REM Created : 06-August-2008
4+
REM Version : 1.0
5+
REM Modifications :
6+
REM
7+
REM Description : Shows the object causing the waits
8+
9+
SELECT b.sid, nvl(substr(a.object_name,1,30),'P1='||b.p1||' P2='||b.p2||' P3='||b.p3) object_name,
10+
a.subobject_name,
11+
a.object_type
12+
FROM dba_objects a, v$session_wait b, x$bh c
13+
WHERE c.obj = a.object_id(+)
14+
AND b.p1 = c.file#(+)
15+
AND b.p2 = c.dbablk(+)
16+
AND b.event = 'db file sequential read'
17+
UNION
18+
SELECT b.sid, nvl(substr(a.object_name,1,30), 'P1='||b.p1||' P2='||b.p2||' P3='||b.p3) object_name,
19+
a.subobject_name,
20+
a.object_type
21+
FROM dba_objects a, v$session_wait b, x$bh c
22+
WHERE c.obj = a.data_object_id(+)
23+
AND b.p1 = c.file#(+)
24+
AND b.p2 = c.dbablk(+)
25+
AND b.event = 'db file sequential read'
26+
ORDER BY 1;
27+
28+
REM End of Script

0 commit comments

Comments
 (0)