Обсуждение: Time trigger

Поиск
Список
Период
Сортировка

Time trigger

От
"Piechu Piechu"
Дата:
hello

I'm new in this list, so sorry if my question seems stupid

Is it possible to invoke store procedure because of time, I mean for example I want my procedure to be invoked every
tenminutes - what should I do to reach this goal 

Greetings
Jakub Piechnik

----------------------------------------------------
"Nieustraszeni Bracia Grimm" - największy przebój tej jesieni
w kinach! Monica Bellucci i Heath Ledger w pełnym przygód
najnowszym filmie Terry'ego Gilliama!
 http://klik.wp.pl/?adr=http%3A%2F%2Fadv.reklama.wp.pl%2Fas%2Fgrimmm.html&sid=570



Re: Time trigger

От
"A. Kretschmer"
Дата:
am  10.11.2005, um 12:46:33 +0100 mailte Piechu Piechu folgendes:
> hello
>
> I'm new in this list, so sorry if my question seems stupid
>
> Is it possible to invoke store procedure because of time, I mean for
> example I want my procedure to be invoked every ten minutes - what
> should I do to reach this goal

You can use the crontab for such thing.

0-59/10 * * * * echo "select * from foo;" | psql test | mail foo@example.com


HTH, Andreas
--
Andreas Kretschmer    (Kontakt: siehe Header)
Heynitz:  035242/47212,      D1: 0160/7141639
GnuPG-ID 0x3FFF606C http://wwwkeys.de.pgp.net
 ===    Schollglas Unternehmensgruppe    ===

Re: Time trigger

От
Tino Wildenhain
Дата:
Piechu Piechu schrieb:
> hello
>
> I'm new in this list, so sorry if my question seems stupid
>
> Is it possible to invoke store procedure because of time, I mean for example I want my procedure to be invoked every
tenminutes - what should I do to reach this goal 
>

Usually one takes the system cron service to start a script
which in turn acts on the database in the way you want.
Since you are using windows, you perhaps have no built in
way (although I remember there was an ability with IE
offline pages you can use to timely trigger things iirc)
but there are many "cron" - like tools for download
you could use.

Postgres has currently no built in for that because
the vast number of instances run on some unices where
cron is common.

HTH
Tino Wildenhain