Re: \d with triggers: more than one row returned by a subquery used as an expression

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: \d with triggers: more than one row returned by a subquery used as an expression
Дата
Msg-id 163710.1642464874@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: \d with triggers: more than one row returned by a subquery used as an expression  (Justin Pryzby <pryzby@telsasoft.com>)
Ответы Re: \d with triggers: more than one row returned by a subquery used as an expression  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Justin Pryzby <pryzby@telsasoft.com> writes:
> On Mon, Jan 17, 2022 at 05:02:00PM -0500, Tom Lane wrote:
>> ISTM the real problem is the assumption that only related triggers could
>> share a tgname, which evidently isn't true.  I think this query needs to
>> actually match on tgparentid, rather than taking shortcuts.

> I don't think that should be needed - tgparentid should match
> pg_partition_ancestors().

Uh, what?  tgparentid is a trigger OID, not a relation OID.

> Is there any reason why WITH ORDINALITY can't work ?
> This is passing the smoke test.

How hard did you try to break it?  It still seems to me that
this can be fooled by an unrelated trigger with the same tgname.

            regards, tom lane



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

Предыдущее
От: Justin Pryzby
Дата:
Сообщение: Re: \d with triggers: more than one row returned by a subquery used as an expression
Следующее
От: Jelte Fennema
Дата:
Сообщение: Re: [EXTERNAL] Re: PQcancel does not use tcp_user_timeout, connect_timeout and keepalive settings