Re: How to send automatically a NOTIFY when a COMMIT is done ?

Поиск
Список
Период
Сортировка
От jboes@nexcerpt.com (Jeff Boes)
Тема Re: How to send automatically a NOTIFY when a COMMIT is done ?
Дата
Msg-id d40a65a1.0201141039.2bd41fa9@posting.google.com
обсуждение исходный текст
Ответы Re: How to send automatically a NOTIFY when a COMMIT is done ?  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
"elisabeth maniez" <emaniez@caramail.com> wrote in message news:<a1q39u$n8d$1@news.tht.net>...
> When a transaction is commited, I would like to execute "automatically" a
> "NOTIFY ..." call

I'd asked about this sort of thing a few months ago (do a search on
"NOTIFY" at groups.google.com).  Your best bet is to write a trigger
in PL/Pgsql that EXECUTEs the NOTIFY.  Even there, you won't be able
to do it at COMMIT time, but only at statement execution time.  If you
want to do it when you commit, you'll have to do it programmatically
rather than through a trigger.

В списке pgsql-general по дате отправления:

Предыдущее
От: "Ian Harding"
Дата:
Сообщение: PSQL Core Dumps
Следующее
От: "Jeffrey W. Baker"
Дата:
Сообщение: Re: Anyway to know which users are connected to postgres?