Re: Index not used in certain nested views but not in others

From: Ron Johnson <ronljohnsonjr(at)gmail(dot)com>
To: "pgsql-generallists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: Re: Index not used in certain nested views but not in others
Date: 2025-04-30 19:58:59
Message-ID: CANzqJaAaU9RJU8G4hDpAHPB+f6xP4Gf-A_=YAk=E-PZgSVhkdg@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, Apr 30, 2025 at 3:51 PM Markus Demleitner <
msdemlei(at)ari(dot)uni-heidelberg(dot)de> wrote:

> Dear List,
>
> I know how tedious mails with a subject of the type "I don't understand
> what the planner does" are, but on this one I'm really stumped.
> Regrettably, the situation is also a bit complex. Hopefully, someone
> will bear with me.
>
> So, in a PostgreSQL 15.12 I have a view over a single table with ~20
> columns (the only relevant columns here are the ones that somehow
> contain "pub[lisher]_did", the others are just there for context; I'm
> going to call these "pubdids" from here on in the prose):
>
[snip]

> Is there anything that would explain that behaviour given I've switched
> off the genetic optimiser and postgres has hopefully exhaustively
> searched the space of plans in both cases?
>

Are the tables regularly analyzed and vacuumed? (The default autovacuum
analyze threshold of 20% is pretty high.)

--
Death to <Redacted>, and butter sauce.
Don't boil me, I'm still alive.
<Redacted> lobster!

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Tom Lane 2025-04-30 21:02:09 Re: Index not used in certain nested views but not in others
Previous Message Greg Sabino Mullane 2025-04-30 16:11:37 Re: alter system appending to a value