public inbox for [email protected]
help / color / mirror / Atom feedFrom: David G. Johnston <[email protected]>
To: sud <[email protected]>
Cc: Laurenz Albe <[email protected]>
Cc: pgsql-general <[email protected]>
Subject: Re: Trigger usecase
Date: Tue, 30 Jul 2024 13:28:35 -0700
Message-ID: <CAKFQuwakdL3D-0wkiou11ahxCtyMkCoraVZFu-bkmJ=NH8cJ2w@mail.gmail.com> (raw)
In-Reply-To: <CAD=mzVVOC=H9zhYn5YF74XMV+7023f5hPvcroSaQu61m7q-yCg@mail.gmail.com>
References: <CAD=mzVU0rx4A0onfC4jHxZ7XreZrk9DNa9pFoGDOjPD1ZhfHgw@mail.gmail.com>
<[email protected]>
<CAD=mzVVOC=H9zhYn5YF74XMV+7023f5hPvcroSaQu61m7q-yCg@mail.gmail.com>
On Tue, Jul 30, 2024 at 11:46 AM sud <[email protected]> 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.
view thread (4+ messages)
reply
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: [email protected]
Cc: [email protected], [email protected], [email protected], [email protected]
Subject: Re: Trigger usecase
In-Reply-To: <CAKFQuwakdL3D-0wkiou11ahxCtyMkCoraVZFu-bkmJ=NH8cJ2w@mail.gmail.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox