Re: mail alert - Mailing list pgsql-sql

From Jasen Betts
Subject Re: mail alert
Date
Msg-id h60vnp$h8t$1@reversiblemaps.ath.cx
Whole thread Raw
In response to mail alert  (Jan Verheyden <jan.verheyden@uz.kuleuven.ac.be>)
List pgsql-sql
On 2009-08-11, Jan Verheyden <jan.verheyden@uz.kuleuven.ac.be> wrote:
>
> Hi All,
>
> I was looking in what way it's possible to alert via mail when some conditi=
> ons are true in a database.
>
> Thanks in advance!

Assuming you mean email, and not ink on paper (hmm, OTOH you could load
postcards into a printer....)

you could do this using NOTIFY and a listener written in some other
langauge,  notify is really neat.

or possibly invoke mail(1) with a plpythonu or C function,

or as superuser you can write a file (using copy ...) and arrange for something else to
look, find it, and mail it.

arbitrary file contents are possible with copy: 

COPY (SELECT NULL) TO myfile_name WITH NULL AS myfile_contents;




pgsql-sql by date:

Previous
From: "Relyea, Mike"
Date:
Subject: Re: simple? query
Next
From: Jasen Betts
Date:
Subject: Re: mail alert