Re: PG does not support one function of its extension pg_hint_plan - Mailing list pgsql-hackers

From Tom Lane
Subject Re: PG does not support one function of its extension pg_hint_plan
Date
Msg-id 1699566.1730469439@sss.pgh.pa.us
Whole thread Raw
In response to Re: PG does not support one function of its extension pg_hint_plan  (Bruce Momjian <bruce@momjian.us>)
List pgsql-hackers
Bruce Momjian <bruce@momjian.us> writes:
> On Fri, Nov  1, 2024 at 11:13:09AM +0800, 李奇隆 wrote:
>> In the GitHub repository for PostgreSQL’s pg_hint_plan extension, there is an
>> issue where the generated join order does not match the assigned join order.
>> After reviewing the source code, I found that this inconsistency with input
>> hints is due to PostgreSQL’s implementation and is not a bug in pg_hint_plan.

> Just to clarify, the bug is not in pg_hint_plan but in the fact that the
> Postgres server ignores "disable_cost of disabled operators in the
> initial phase of cost estimation," right?

We have never promised anything about supporting pg_hint_plan.

Having said that, this analysis is all obsolete in the wake of
commit e22253467.  Somebody (not me) would need to look into
whether a similar effect still exists with the new model for
disabling plan types.

Also, there's a highly relevant thread over at

https://www.postgresql.org/message-id/flat/CA%2BTgmoZY%2BbaV-T-5ifDn6P%3DL%3DaV-VkVBrPmi0TQkcEq-5Finww%40mail.gmail.com

It would probably be better to bring any conclusions to that
thread instead of starting a new one.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Greg Sabino Mullane
Date:
Subject: Re: Changing the default random_page_cost value
Next
From: Aleksander Alekseev
Date:
Subject: Re: Having problems generating a code coverage report