Re: How to send automatically a NOTIFY when a COMMIT is done ?
В списке pgsql-general по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | Re: How to send automatically a NOTIFY when a COMMIT is done ? |
| Дата | |
| Msg-id | 18558.1011039933@sss.pgh.pa.us обсуждение |
| Ответ на | Re: How to send automatically a NOTIFY when a COMMIT is done ? (jboes@nexcerpt.com (Jeff Boes)) |
| Список | pgsql-general |
jboes@nexcerpt.com (Jeff Boes) writes:
> "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.
Since the NOTIFY won't actually be sent to the client until/unless the
transaction commits, I should think a NOTIFY would do fine.
regards, tom lane
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера