Re: Implicitly created operator family not listed by pg_event_trigger_ddl_commands

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: Implicitly created operator family not listed by pg_event_trigger_ddl_commands
Дата
Msg-id YoYGKWWwrB+8AlV/@paquier.xyz
обсуждение исходный текст
Ответ на Implicitly created operator family not listed by pg_event_trigger_ddl_commands  (LEMAIRE Leslie (Chargée de mission) - SG/SNUM/UNI/DRC <leslie.lemaire@developpement-durable.gouv.fr>)
Список pgsql-bugs
On Fri, May 06, 2022 at 02:26:42PM +0900, Masahiko Sawada wrote:
> DefineOpClass() calls CreateOpFamily() to create the operator family
> but in CreateOpFamily() we don't report the new object to event
> triggers. The event by CREATE OPERATOR FAMILY is normally reported by
> ProcessUtilitySlow(). I've confirmed this happens on all supported
> branches. I've attached a patch to fix it.

Hmm.  It looks like it makes sense to back-patch that.  That's indeed
a bit surprising to not have an event trigger inform about both.

+-- CRAETE OPERATOR CLASS without FAMILY clause should report
+-- both CRAETE OPERATOR FAMILY and CRAETE OPERATOR CLASS
Got the same typo here, repeated three times.

-           tmpAddr = CreateOpFamily(stmt->amname, opcname,
+           tmpAddr = CreateOpFamily(&opfstmt, stmt->amname, opcname,
                                     namespaceoid, amoid);
CreateOpFamily() does not need its second argument now that you pass
down a CreateOpFamilyStmt as first argument, no?
--
Michael

Вложения

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

Предыдущее
От: Michael Paquier
Дата:
Сообщение: Re: BUG #17485: Records missing from Primary Key index when doing REINDEX INDEX CONCURRENTLY
Следующее
От: Andrey Lepikhov
Дата:
Сообщение: Re: Negative value of numGroups