From: | "Josh Berkus" <josh(at)agliodbs(dot)com> |
---|---|
To: | Jimmie Fulton <JFulton(at)ehso(dot)emory(dot)edu>, "'pgsql-sql(at)postgresql(dot)org'" <pgsql-sql(at)postgresql(dot)org> |
Subject: | Re: Functions performed on intervals |
Date: | 2001-07-12 19:10:46 |
Message-ID: | web-84978@davinci.ethosmedia.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
Jimmie,
> Thanks for your response,
You're welcome.
> What you are saying here is that I will indeed need an external timed
> event
> (cron) to update a field/history table of some fashion, correct?
> This is my
> main question.
Yes. Absolutely you will. Unless, of course, your users are already
forced to go though a manual month-end procedure, in which case it could
be tied to that.
This is actually really easy to set up:
1. Create a shell script that calls psql and a SQL script in 2;
2. Create a SQL script that calls all of the functions that you want to
run on a (daily/weekly/monthly) basis.
3. Create a cron item that calls the shell script (1.).
Handling errors etc. obviously adds a layer of complexity to the
scripting. I also have the functions write to a schedule_log table
showing what they've done.
-Josh
______AGLIO DATABASE SOLUTIONS___________________________
Josh Berkus
Complete information technology josh(at)agliodbs(dot)com
and data management solutions (415) 565-7293
for law firms, small businesses fax 621-2533
and non-profit organizations. San Francisco
From | Date | Subject | |
---|---|---|---|
Next Message | James Orr | 2001-07-12 20:25:04 | Referencing a view? |
Previous Message | Jimmie Fulton | 2001-07-12 18:33:43 | RE: Functions performed on intervals |