Re: Trigger usecase

Поиск
Список
Период
Сортировка
От David G. Johnston
Тема Re: Trigger usecase
Дата
Msg-id CAKFQuwakdL3D-0wkiou11ahxCtyMkCoraVZFu-bkmJ=NH8cJ2w@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Trigger usecase  (sud <suds1434@gmail.com>)
Ответы Re: Trigger usecase
Список pgsql-general
On Tue, Jul 30, 2024 at 11:46 AM sud <suds1434@gmail.com> wrote:

Not sure of the exact pros and cons, but we were following certain rules like , if it's business logic which needs to be implemented in Database, then it should not be done using triggers but rather should be done through database procedure/functions. Hope this understanding correct.

That is my personal take.  For process-oriented stuff you can follow the trail of calls all the way through to the end of the process and its final result.  With triggers you follow the trail to the insert/update/delete then stop thinking that's it, while in reality it continues because you have triggers performing yet more work.

David J.

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