Re: Correct docs re: rewriting indexes when table rewrite is skipped

James Coleman <jtc331@gmail.com>

From: James Coleman <jtc331@gmail.com>
To: Robert Haas <robertmhaas@gmail.com>
Cc: Matthias van de Meent <boekewurm+postgres@gmail.com>, pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2022-03-31T13:17:46Z
Lists: pgsql-hackers

Attachments

On Wed, Mar 30, 2022 at 5:41 PM Robert Haas <robertmhaas@gmail.com> wrote:
>
> On Wed, Mar 30, 2022 at 4:33 PM James Coleman <jtc331@gmail.com> wrote:
> > Hmm, having it match the way it works makes sense. Would you feel
> > comfortable with an intermediate step (queueing up that as a larger
> > change) changing the clause to something like "indexes will still have
> > to be rebuilt unless the system can guarantee that the sort order is
> > proven to be unchanged" (with appropriate wordsmithing to be a bit
> > less verbose if possible)?
>
> Yeah, that seems fine. It's arguable how much detail we should go into
> here - but a statement of the form you propose is not misleading, and
> that's what seems most important to me.

All right, thanks for feedback. Attached is v2 with such a change.
I've not included examples, and I'm about 50/50 on doing so. What are
your thoughts on adding in parens "e.g., changing from varchar to text
avoids rebuilding indexes while changing from text to a domain of text
with a different collation will require rebuilding indexes"?

Thanks,
James Coleman

Commits

  1. docs: Changing column type doesn't always require an index rebuild.