Recent site activity

Oracle: ash_io.sql


/*
EVENT                         P3 OBJN                      OTYPE                FILEN BLOCKN SQL_ID
------------------------- ------ ------------------------- --------------- ---------- ------ -------
db file sequential read        1 52956 ORDER_ITEMS         TABLE PARTITION          4  11035 41zu158rqf4kf
db file sequential read        1 53042 ORDER_ITEMS_PK      INDEX                    4   7075 41zu158rqf4kf
db file sequential read        1 52947 CUSTOMERS           TABLE PARTITION          4  33336 0bzhqhhj9mpaa
db file sequential read        1 52952 ORDER_ITEMS         TABLE PARTITION          4  11801 41zu158rqf4kf
db file sequential read        1 53043 ORDER_PK            INDEX                    4  39085 3hatpjzrqvfn7
db file sequential read        1 52946 CUSTOMERS           TABLE PARTITION          4  22568 75621g9y3xmvd
db file sequential read        1 53042 ORDER_ITEMS_PK      INDEX                    4  35048 41zu158rqf4kf
db file sequential read        1 52962 ORDER_ITEMS         TABLE PARTITION          4  37166 0yas01u2p9ch4
db file sequential read        1 52946 CUSTOMERS           TABLE PARTITION          4  31437 75621g9y3xmvd
*/
col block_type for a18
col objn for a25
col otype for a15
col event for a25
select
       event,
       --ash.p1,
       --ash.p2,
       ash.p3, 
       CURRENT_OBJ#||' '||o.object_name objn,
       o.object_type otype,
       CURRENT_FILE# filen,
       CURRENT_BLOCK# blockn, 
       ash.SQL_ID
from v$active_session_history ash,
      all_objects o
where event like 'db file s%'
   and o.object_id (+)= ash.CURRENT_OBJ#
Order by sample_time
/
Comments