Re: mail alert - Mailing list pgsql-general

From Sam Mason
Subject Re: mail alert
Date
Msg-id 20090814150557.GN5407@samason.me.uk
Whole thread Raw
In response to Re: mail alert  ("Ow Mun Heng" <ow.mun.heng@wdc.com>)
List pgsql-general
On Fri, Aug 14, 2009 at 09:52:02AM +0800, Ow Mun Heng wrote:
> Christophe Pettus wrote:
> >On Aug 11, 2009, at 12:19 AM, Jan Verheyden wrote:
> >> I was looking in what way it's possible to alert via mail when some
> >> conditions are true in a database.
>
> >An external script that connects to the database, checks for the
> >condition, and sends the email if it exists is probably your best
> >solution.  You might want to take a look at check_postgres:
>
> >    http://bucardo.org/check_postgres/
>
> I would look forward to having such a feature in Postgres actually. Right
> now, I'm using cron to do those checks.

You could use one of the embedded languages (plperl or plpython) to do
the sending of emails if you want.  You'd still need something "outside"
the database to actually start the function running though.

--
  Sam  http://samason.me.uk/

pgsql-general by date:

Previous
From: Teodor Sigaev
Date:
Subject: Re: FILLFACTOR for GIN indexes in 8.3.7
Next
From: "Ewgenij Sokolovski"
Date:
Subject: Getting database data from the PostgreSQL file system