Last active
March 26, 2019 13:41
-
-
Save llagerlof/1b8648ec495a1a967985cc0515c9e47b to your computer and use it in GitHub Desktop.
How to kill oracle connections by session
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT * FROM V$SESSION WHERE SCHEMANAME = 'MYSCHEMA' AND MACHINE = 'applicationserver.localdomain' AND STATUS = 'INACTIVE'; | |
ALTER SYSTEM KILL SESSION '87,33311'; -- SID,SERIAL | |
ALTER SYSTEM DISCONNECT SESSION '87,33311' IMMEDIATE; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment