Listing Sessions Connected by SID

When we are preparing to move a database or something like that, it’s useful to know if there is any session connecting by SID, right?

It can be done with:

select distinct machine,username,inst_id from gv$session where service_name = 'SYS$USERS';

Cheers!

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Discover more from grepOra

Subscribe now to keep reading and get access to the full archive.

Continue reading