Re: Doing better at HINTing an appropriate column within errorMissingColumn() - Mailing list pgsql-hackers

From Peter Geoghegan
Subject Re: Doing better at HINTing an appropriate column within errorMissingColumn()
Date
Msg-id CAM3SWZT6-ytsMHZJSb_x0WsnWuF=iHBABtfANJ3x7kNDN-7tYw@mail.gmail.com
Whole thread Raw
In response to Re: Doing better at HINTing an appropriate column within errorMissingColumn()  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Doing better at HINTing an appropriate column within errorMissingColumn()  (Gavin Flower <GavinFlower@archidevsys.co.nz>)
List pgsql-hackers
On Tue, Jun 17, 2014 at 2:53 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> I'm not proposing an immutable cutoff.  Something that scales with the
> string length might be a good idea, or we could make it a multiple of
> the minimum observed distance, or probably there are a dozen other things
> we could do.  I'm just saying that if we have an alternative at distance
> 3, and another one at distance 4, it's not clear to me that we should
> assume that the first one is certainly what the user had in mind.
> Especially not if all the other alternatives are distance 10 or more.

The patch just looks for the match with the lowest distance, passing
the lowest observed distance so far as a "max" to the distance
calculation function. That could have some value in certain cases.
People have already raised general concerns about added cycles and/or
clutter.

-- 
Peter Geoghegan



pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: Atomics hardware support table & supported architectures
Next
From: Gavin Flower
Date:
Subject: Re: Doing better at HINTing an appropriate column within errorMissingColumn()