Re: sending mail from Postgres - Mailing list pgsql-general

From Tony Caduto
Subject Re: sending mail from Postgres
Date
Msg-id 43B7EE7A.9030609@amsoftwaredesign.com
Whole thread Raw
In response to Re: sending mail from Postgres  (Tony Caduto <tony.caduto@amsoftwaredesign.com>)
List pgsql-general
> And you can code a trigger that fires when there is a difference of 60
> days between dates(I have apps that do so...,and the trigger sends a email)

I guess I should expand on this more, the trigger is fired via a
insert/update into a table called logons, when a user logs on to the
system a record is inserted(if it does not exist) or updated.  Once
fired the trigger function then compares dates on the accounts the user
is reviewing, if there is a 60 day difference a email is sent to
managers letting them know that the user has accounts that have not been
reviewed in the last 60 days.

The trigger is of course fired by a insert/delete or update, but the
logic inside determines if the trigger should actually do something or
just be aborted.

Tony

pgsql-general by date:

Previous
From: Frank van Vugt
Date:
Subject: just an inconvenience, or.... : failed queries don't appear in the log anymore since v8.?.?
Next
From: Ian Harding
Date:
Subject: Re: WAL logs multiplexing?