From: | "Nikolai Cheltsov" <begimot(at)gmail(dot)com> |
---|---|
To: | pgsql-novice(at)postgresql(dot)org |
Subject: | connection management |
Date: | 2007-10-18 10:38:15 |
Message-ID: | bf7b1e3e0710180338n4e9f0b0ha1abb0475faec014@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-novice |
As I am not sure how to execute this function(is there analog of DUAL table
in Oracle), I am using something like this;
SELECT pg_cancel_backend(15429) FROM pg_stat_activity;
The result is;
ERROR: function pg_cancel_backend(integer) does not exist
Aby Ideas?- Hide quoted text -
On 10/18/07, A. Kretschmer <andreas(dot)kretschmer(at)schollglas(dot)com> wrote:
>
> am Thu, dem 18.10.2007, um 11:34:29 +0200 mailte Nikolai Cheltsov
> folgendes:
> > Hi All,
> >
> > I could not find any information about this simple question.
> >
> > How can I understand who is connected to a given database? How can I
> kill all
> > connections to a database in order, for example, to remove it?
>
> You can use pg_stat_activity to find all connected backends, and you can
> use pg_cancel_backend(pid int) to kill a specific backend.
>
> Andreas
> --
> Andreas Kretschmer
> Kontakt: Heynitz: 035242/47150, D1: 0160/7141639 (mehr: -> Header)
> GnuPG-ID: 0x3FFF606C, privat 0x7F4584DA http://wwwkeys.de.pgp.net
>
From | Date | Subject | |
---|---|---|---|
Next Message | A. Kretschmer | 2007-10-18 10:48:37 | Re: manage connections |
Previous Message | A. Kretschmer | 2007-10-18 09:44:55 | Re: manage connections |