Monday, June 8, 2009

How to kill sessions in Oracle

To kill a session in Oracle, first find the SID and serial # of the session:

select sid, serial#, username, status from v$session where username=upper('username');

Next, use the alter system command to kill the session (note the SID and serial # in single quotes):

alter system kill session 'sid, serial#';

No comments: