Re: Allowing ALTER TYPE to change storage strategy

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
Cc: Tomas Vondra <tomas(dot)vondra(at)2ndquadrant(dot)com>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Allowing ALTER TYPE to change storage strategy
Date: 2020-03-06 17:23:58
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

"David G. Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com> writes:
> Is there also an issue with whether the type has implemented compression or
> not - i.e., should the x->e and m->e paths be forbidden too? Or is it
> always the case a non-plain type is compressible and the other non-plain
> options just switch between preferences (so External just says "while I can
> be compressed, please don't")?

Yeah, the only relevant issue here is "can it be toasted, or not?". A
data type doesn't have direct control of which toasting options can be
applied, nor does it need to, as long as the C functions apply the
correct detoast macros.

> Can you please include an edit to [1] indicating that "e" is the
> abbreviation for External and "x" is Extended (spelling out the other two
> as well). Might be worth a comment at [2] as well.
> [1]
> [2]

Done in [1]; I didn't see much point in changing [2].

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2020-03-06 17:29:34 Re: [postgis-devel] About EXTENSION from UNPACKAGED on PostgreSQL 13
Previous Message Tom Lane 2020-03-06 17:20:43 Re: Allowing ALTER TYPE to change storage strategy