Last active
February 9, 2016 03:00
-
-
Save schlueter/fc7a418a8f8a5fac5a84 to your computer and use it in GitHub Desktop.
Useful Oracle Queries
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
# discover what programs are still connected to a db | |
select sid,serial#,program from v$session where username = '<your_schema>'; | |
# and forcibly disconnect them | |
select 'alter system kill session ''' || sid || ',' || serial# || ''';' from v$session where username = '<your_schema>' | |
#Shutdown and restart cdb and pdb | |
shutdown; | |
#then | |
startup; | |
#then | |
startup pluggable database <service_name>; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment