Re: Querying an index's btree version

From: Peter Geoghegan <pg(at)bowt(dot)ie>
To: Darren Lafreniere <dlafreniere(at)onezero(dot)com>
Cc: "pgsql-generallists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: Re: Querying an index's btree version
Date: 2020-03-11 21:18:42
Message-ID: CAH2-Wz=mNy95mS30DbcXqUpiWUVWU9vwz4GqzQcN5u_FHE1Rbg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, Mar 11, 2020 at 2:13 PM Darren Lafreniere
<dlafreniere(at)onezero(dot)com> wrote:
> when you restore a DB from a backup, does the restored index use the old format or the latest one?

If you use pg_restore, it uses the latest index format.

If you're using pg_upgrade, the version won't change unless and until
you REINDEX. This includes cases where you're running pg_upgrade
against a restored physical backup.

--
Peter Geoghegan

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Peter J. Holzer 2020-03-11 21:22:43 Re: strange locks on PG 11 with Golang programs
Previous Message Darren Lafreniere 2020-03-11 21:12:53 Re: Querying an index's btree version