Re: postgres_fdw hint messages

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Nathan Bossart <nathandbossart(at)gmail(dot)com>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: postgres_fdw hint messages
Date: 2022-09-01 23:08:49
Message-ID: 789102.1662073729@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Nathan Bossart <nathandbossart(at)gmail(dot)com> writes:
> On Fri, Aug 26, 2022 at 12:35:38PM -0400, Tom Lane wrote:
>> I vote for just dropping all these hints for now, while leaving the
>> door open for anyone who wants to write closest-match-offering code.

> Here is a quickly-hacked-together proof-of-concept for using Levenshtein
> distances to determine which option to include in the hint. Would
> something like this suffice? If so, I will work on polishing it up a bit.

Seems reasonable to me, but

(1) there probably needs to be some threshold of closeness, so we don't
offer "foobar" when the user wrote "huh"

(2) there are several places doing this now, and there will no doubt
be more later, so we need to try to abstract the logic so it can be
shared.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message samay sharma 2022-09-01 23:12:14 Re: [RFC] building postgres with meson - v11
Previous Message Junwang Zhao 2022-09-01 23:08:44 Re: [PATCH v1] fix potential memory leak in untransformRelOptions