Re: Disallow redundant indexes - Mailing list pgsql-hackers

From Nathan Bossart
Subject Re: Disallow redundant indexes
Date
Msg-id aA_-XAZCAAnu3rzn@nathan
Whole thread Raw
In response to Re: Disallow redundant indexes  (Sami Imseih <samimseih@gmail.com>)
Responses Re: Disallow redundant indexes
List pgsql-hackers
On Mon, Apr 28, 2025 at 01:12:18PM -0500, Sami Imseih wrote:
> If I had a dollar for every time I asked a user to check for duplicate
> indexes :) So
> I think it's a good idea to provide some way to detect these ( besides
> a query in the
> Wiki ), but I don't think we should prevent it.
> 
> While a WARNING will be a good to have, it could easily go unnoticed,
> but it's still good to have.

I don't doubt that this is a problem in the field, but I'm not sure I'm
convinced it's worthwhile to emit a warning that only appears for exact
duplicates and is very easily missed, not to mention that the user could be
intentionally creating the index.

-- 
nathan



pgsql-hackers by date:

Previous
From: Nathan Bossart
Date:
Subject: Re: teach pg_upgrade to handle in-place tablespaces
Next
From: Tom Lane
Date:
Subject: Re: Large expressions in indexes can't be stored (non-TOASTable)