From 96eb94d3c1dbee6d237689045ce0ae17acc96008 Mon Sep 17 00:00:00 2001 From: Hari Sekhon Date: Wed, 5 Aug 2020 18:52:46 +0100 Subject: [PATCH] updated postgres_stale_connections.sql --- sql/postgres_stale_connections.sql | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sql/postgres_stale_connections.sql b/sql/postgres_stale_connections.sql index 823776b3..99d6a473 100644 --- a/sql/postgres_stale_connections.sql +++ b/sql/postgres_stale_connections.sql @@ -15,6 +15,10 @@ -- List PostgreSQL stale connections that have been idle > 10 mins -- +-- Can be used to kill connections using the pids returned, eg. +-- +-- SELECT pg_terminate_backend(pid) +-- -- Tested on PostgreSQL 12.3 SELECT