pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feed(no subject)
3+ messages / 3 participants
[nested] [flat]
* (no subject)
@ 2002-05-23 11:27 rhema@bhasin.co.in
0 siblings, 2 replies; 3+ messages in thread
From: rhema@bhasin.co.in @ 2002-05-23 11:27 UTC (permalink / raw)
To: pgsql-sql
hello,
I need to know if there are any database event triggers
in postgres like i want the trigger to run periodically(every day just like
crontab on unix), i need to delete the records in a table automatically
after a period of say 90 days.
It is possible to create trigger on table before insert or update but if
there are no insertions or updations on the table, the record will remain in
the database.
looking forward for the suggestions.
Thanx in advance
Hema
_____________________________________
Powered by EBHASIN V-Mail Service.
Visit http://www.ebhasin.com
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re:
@ 2002-05-23 13:41 Rajesh Kumar Mallah. <mallah@trade-india.com>
parent: rhema@bhasin.co.in
1 sibling, 0 replies; 3+ messages in thread
From: Rajesh Kumar Mallah. @ 2002-05-23 13:41 UTC (permalink / raw)
To: rhema@bhasin.co.in; pgsql-sql
Hi,
Even i would love to hear if there is any such feature.
but there is an easy work around, use the unix crontab
and -c option of psql to pass the query from the crontab file
it self.
regds
mallah.
On Thursday 23 May 2002 04:57 pm, rhema@bhasin.co.in wrote:
> hello,
> I need to know if there are any database event triggers
> in postgres like i want the trigger to run periodically(every day just like
> crontab on unix), i need to delete the records in a table automatically
> after a period of say 90 days.
>
> It is possible to create trigger on table before insert or update but if
> there are no insertions or updations on the table, the record will remain
> in the database.
> looking forward for the suggestions.
>
> Thanx in advance
> Hema
>
> _____________________________________
> Powered by EBHASIN V-Mail Service.
> Visit http://www.ebhasin.com
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
--
Rajesh Kumar Mallah,
Project Manager (Development)
Infocom Network Limited, New Delhi
phone: +91(11)6152172 (221) (L) ,9811255597 (M)
Visit http://www.trade-india.com ,
India's Leading B2B eMarketplace.
^ permalink raw reply [nested|flat] 3+ messages in thread
* Re:
@ 2002-05-23 15:24 Bruno Wolff III <bruno@wolff.to>
parent: rhema@bhasin.co.in
1 sibling, 0 replies; 3+ messages in thread
From: Bruno Wolff III @ 2002-05-23 15:24 UTC (permalink / raw)
To: rhema@bhasin.co.in; +Cc: pgsql-sql
On Thu, May 23, 2002 at 11:27:20 +0000,
rhema@bhasin.co.in wrote:
> hello,
> I need to know if there are any database event triggers
> in postgres like i want the trigger to run periodically(every day just like
> crontab on unix), i need to delete the records in a table automatically
> after a period of say 90 days.
>
> It is possible to create trigger on table before insert or update but if
> there are no insertions or updations on the table, the record will remain
> in the database.
> looking forward for the suggestions.
Probably you just ran to run a cron job that deletes records older than
90 days in order to reclaim space. If it is important that transactions
not see this older data, than you want to write your selects so that older
records are not visible.
^ permalink raw reply [nested|flat] 3+ messages in thread
end of thread, other threads:[~2002-05-23 15:24 UTC | newest]
Thread overview: 3+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2002-05-23 11:27 rhema@bhasin.co.in
2002-05-23 13:41 ` Re: Rajesh Kumar Mallah. <mallah@trade-india.com>
2002-05-23 15:24 ` Re: Bruno Wolff III <bruno@wolff.to>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox