Re: Need "InBetween" (not just Before and After) Trigger
В списке pgsql-general по дате отправления:
| От | Tom Lane |
|---|---|
| Тема | Re: Need "InBetween" (not just Before and After) Trigger |
| Дата | |
| Msg-id | 28013.979592067@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | Re: Need "InBetween" (not just Before and After) Trigger (Matt Doucleff <matt@digitalfountain.com>) |
| Ответы |
Re: Need "InBetween" (not just Before and After) Trigger
|
| Список | pgsql-general |
Matt Doucleff <matt@digitalfountain.com> writes:
> For example, say I want to create a file when a row is inserted, and
> modify that file when the row is modified. If a transaction fails, I
> need to undo my changes to the filesystem.
Unless you want to implement your own undo log, I'd suggest rethinking
this. What you really want is a trigger fired at commit time, ie a
deferred trigger, so that you don't have to worry about rolling back
your outside actions. I believe we have that facility for foreign key
triggers, not sure if it's available for general use yet ...
regards, tom lane
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера