Re: [PATCH] Add pg_get_event_trigger_ddl() function

From: Jim Jones <jim(dot)jones(at)uni-muenster(dot)de>
To: Zsolt Parragi <zsolt(dot)parragi(at)percona(dot)com>, Ian Lawrence Barwick <barwick(at)gmail(dot)com>
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: [PATCH] Add pg_get_event_trigger_ddl() function
Date: 2026-07-20 15:13:24
Message-ID: 97afdca7-3fb7-468d-9924-a1067f4bb254@uni-muenster.de
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi Ian

Thanks for the patch! Here a few comments on v2:

== shadow variable ==

The function pg_get_event_trigger_ddl_internal has a bool parameter
named owner, and its body has a char* with the same name.

== trailing XXX (placeholder?) ==

+ * CREATE EVENT TRIGGER statement; XXX

== typo (2x the) ==

+ is false, the the corresponding <literal>ENABLE</literal> clause is

=== switch without default ==

I realise that "switch (evtForm->evtenabled)" already tests all possible
values of evtenable, but I'm wondering if we really should let it
silently finish the buffer like "ALTER EVENT TRIGGER foo ;" if evtenable
ever gets a different value. I'd argue that an error message would be
better than a malformed DDL. What do you think?

Best, Jim

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Greg Burd 2026-07-20 15:36:11 Re: [PATCH] Batched clock sweep to reduce cross-socket atomic contention
Previous Message Timo J. Rinne 2026-07-20 15:00:20 [PATCH] Require a declaration before using explicit_bzero