Re: multiple indexes on the same column - Mailing list pgsql-general

From Tom Lane
Subject Re: multiple indexes on the same column
Date
Msg-id 2157.1555088856@sss.pgh.pa.us
Whole thread Raw
In response to Re: multiple indexes on the same column  (Andres Freund <andres@anarazel.de>)
Responses Re: multiple indexes on the same column
List pgsql-general
Andres Freund <andres@anarazel.de> writes:
> On 2019-04-12 09:51:51 -0400, Tom Lane wrote:
>> Tiffany Thang <tiffanythang@gmail.com> writes:
>>> Can someone explain the use of creating multiple indexes on the same
>>> column?

>> There is none, unless the indexes have different properties (e.g.
>> different opclasses and/or index AMs).

> Well, it can be beneficial to create a new index concurrently, and then
> drop the old one concurrently.

Right, but in that situation there's no intent to keep both indexes
in place.  You're just putting up with extra overhead temporarily
as a means to avoid taking an exclusive lock.

            regards, tom lane



pgsql-general by date:

Previous
From: Andres Freund
Date:
Subject: Re: multiple indexes on the same column
Next
From: Paul van der Linden
Date:
Subject: Safe to delete files?