Re: Automation - Mailing list pgsql-novice

From ghaverla@freenet.edmonton.ab.ca
Subject Re: Automation
Date
Msg-id Pine.A41.3.95.1001012194416.42162B-100000@freenet.edmonton.ab.ca
Whole thread Raw
In response to Automation  ("Jerome Macaranas" <macky@edsamail.com>)
List pgsql-novice
On Fri, 13 Oct 2000, Jerome Macaranas wrote:

> I need to create reports every month for the marketing people...
>
> I need suggestion on how to automate that...
>
> I thought of querying  but it will make the mail server slow and cause it to hang....
>
> Hope you can help me...  Thanks is adance..

Pick a language which has a libpq interface (C, C++, perl, ...)
and write your queries with that program/interface to
PostgreSQL.  Have the results of the queries either
sent to the appropriate printer or mailed from within
the program.  You can have cron execute the program/script
(as a particular user if needed) whenever you want.
Every 4th sunday at 3:03 am, whatever.  Perl has
modules for talking to PostgreSQL and mail, which
takes a lot of work out of it, but any language
will do.  As far as when it executes, see the man page on
how to set up cron for your purposes.

Gord

Matter Realisations     http://www.materialisations.com/
Gordon Haverland, B.Sc. M.Eng. President
101  9504 182 St. NW    Edmonton, AB, CA  T5T 3A7
780/481-8019            ghaverla @ freenet.edmonton.ab.ca
780/993-1274 (cell)



pgsql-novice by date:

Previous
From: "Jerome Macaranas"
Date:
Subject: Automation
Next
From: "Jerome Macaranas"
Date:
Subject: Automation again more info.. HELP