Created
May 21, 2013 08:27
-
-
Save ctrl-shift/5618320 to your computer and use it in GitHub Desktop.
postgres terminate all connections to db
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 pg_terminate_backend(pid) | |
from pg_stat_activity | |
where datname = 'db name' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment