On Friday, May 3, 2024, Peter Burbery <petercullenburb...@gmail.com> wrote:

> Dear pgsql-hackers,
>
> One-line Summary:
> Proposal to introduce the CREATE OR REPLACE syntax for EVENT TRIGGER in
> PostgreSQL.
>
> Business Use-case:
> Currently, to modify an EVENT TRIGGER, one must drop and recreate it. This
> proposal aims to introduce a CREATE OR REPLACE syntax for EVENT TRIGGER,
> similar to other database objects in PostgreSQL, to simplify this process
> and improve usability.
>
> Contact Information:
> Peter Burbery
> peter.cullen.burb...@gmail.com
>
> I look forward to your feedback on this proposal.
>

Its doesn’t seem like that big an omission, especially since unlike views
and functions you can’t actually affect dependencies on an event trigger.
But the same can be said of normal triggers and they already have an “or
replace” option.  So, sure, if you come along and offer a patch for this it
seems probable it would be accepted.  I’d just be a bit sad it probably
would take away from time that could spent on more desirable features.

As for your proposal format, it is a quite confusing presentation to send
to an open source project.  Also, your examples are overly complex, and
crammed together, for the purpose and not enough effort is spent actually
trying to demonstrate why this is needed when “drop if exists” already is
present.  A much better flow is to conditionally drop the existing object
and create the new one all in the same transaction.

David J.

Reply via email to