CHECK THE SESSIONS ACCESSING TABLE OBJECTS IN ORACLE

If you want to see the sessions which currently access a particular object like table,index etc.. you can use v$access view to see both read and write operations performed by an user or application session

kish@exdbx<>select * from v$access where OBJECT='TABX' and TYPE='TABLE';

   SID                                  OWNER                               OBJECT                                     TYPE
---------- ---------------------------------------------------------------- --------------- ----------------------------------------------------------------
        54 TEST                                                             TABX            TABLE

Alternatively if someone executes a write operation like insert or update on a table, then you can use v$locked_objects

kish@exdbx<>select * from v$locked_object;


  XIDUSN    XIDSLOT     XIDSQN   OBJECT_ID  SESSION_ID ORACLE_USERNAME OS_USER_NAME            PROCESS          LOCKED_MODE
---------- ---------- ---------- ---------- ---------- --------------- --------------- ------------------------ -----------
         6         27       1928      89028         54 TEST            kisha           12520:20912                     3

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 )

Google photo

You are commenting using your Google 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 )

Connecting to %s