Re: [PATCH] Infinite loop while acquiring new TOAST Oid - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [PATCH] Infinite loop while acquiring new TOAST Oid
Date
Msg-id 762132.1669672673@sss.pgh.pa.us
Whole thread Raw
In response to Re: [PATCH] Infinite loop while acquiring new TOAST Oid  (Andres Freund <andres@anarazel.de>)
Responses Re: [PATCH] Infinite loop while acquiring new TOAST Oid
List pgsql-hackers
Andres Freund <andres@anarazel.de> writes:
> On 2022-11-29 00:24:49 +0300, Nikita Malakhov wrote:
>> 2) Upgrading to 64-bit id would require re-toasting old TOAST tables. Or
>> there is some way to distinguish old tables from new ones?

> The catalog / relcache entry should suffice to differentiate between the two.

Yeah, you could easily look at the datatype of the first attribute
(in either the TOAST table or its index) to determine what to do.

As I said before, I think there's a decent argument that some people
will want the option to stay with 4-byte TOAST OIDs indefinitely,
at least for smaller tables.  So even without the fact that forced
conversions would be horridly expensive, we'll need to continue
support for both forms of TOAST table.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: fixing CREATEROLE
Next
From: Peter Geoghegan
Date:
Subject: Re: Add 64-bit XIDs into PostgreSQL 15