Re: pg_dump crash on identity sequence with not loaded attributes

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Artur Zakirov <zaartur(at)gmail(dot)com>
Cc: Peter Eisentraut <peter(at)eisentraut(dot)org>, PostgreSQL mailing lists <pgsql-bugs(at)lists(dot)postgresql(dot)org>
Subject: Re: pg_dump crash on identity sequence with not loaded attributes
Date: 2024-12-11 15:48:49
Message-ID: 482446.1733932129@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

Artur Zakirov <zaartur(at)gmail(dot)com> writes:
> On Tue, 10 Dec 2024 at 22:15, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>> The attached patch also gets rid of the dubious coding in
>> getPublicationNamespaces. We might get push-back on that ignoring
>> schemas belonging to extensions, but if so I'd prefer to see the
>> behavior coded in a more transparent fashion.

> But other than that it seems the patch breaks dumps of mapping of a
> publication with the public namespace. The issue with the public
> namespace is mentioned in the original thread of the feature of adding
> schema mapping [1]. I couldn't find in the thread if it was addressed
> in the end. With the new patch the following mapping won't be mapped:
> create publication pub_test for tables in schema public;

Ouch. Okay, I agree that's probably bad, but then it raises the
question of why this filter exists at all. It certainly seems
100% magic and undocumented that it does the "right" thing for
these cases.

In any case, that's mostly orthogonal to the problem with identity
sequences. I now propose leaving out that change and just pushing
the change in getOwnedSeqs(). The publication-namespace business
should be discussed on its own thread.

regards, tom lane

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2024-12-11 20:37:08 Re: TimestampTz->Text->TimestampTz casting fails with DateStyle 'Postgres'
Previous Message Марат Гасанян 2024-12-11 14:47:23 Problem with constraint unique.