Re: [PATCH] backend: compare word-at-a-time in bcTruelen

From: Dimitri Fontaine <dfontaine(at)hi-media(dot)com>
To: Jeremy Kerr <jk(at)ozlabs(dot)org>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Stephen Frost <sfrost(at)snowman(dot)net>, Stefan Kaltenbrunner <stefan(at)kaltenbrunner(dot)cc>, Robert Haas <robertmhaas(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org, Alvaro Herrera <alvherre(at)commandprompt(dot)com>, Gurjeet Singh <singh(dot)gurjeet(at)gmail(dot)com>
Subject: Re: [PATCH] backend: compare word-at-a-time in bcTruelen
Date: 2009-06-26 07:16:29
Message-ID: 2E117E25-084A-4B8D-9C59-39F5FD4363DE@hi-media.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi,

Le 26 juin 09 à 05:20, Jeremy Kerr a écrit :
>> Unfortunately, the cases with lots of padding spaces are probably
>> much less probable than the cases with fewer. It would be unpleasant
>> for example if this patch resulted in a severe performance
>> degradation for a "canonical" example of char(n) being used properly,
>> such as char(2) for US state abbreviations.
>
> Yep, makes sense. The other consideration is stock-ticker symbols, I
> assume they may also be stored in CHAR(small n) columns.

Could this optimisation only kicks in when n is "big enough"?
I'm don't know if this part of the code knows the typmod...

Regards,
--
dim

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Scara Maccai 2009-06-26 07:37:22 Query progress indication - an implementation
Previous Message KaiGai Kohei 2009-06-26 04:08:37 [PATCH] [v8.5] Security checks on largeobjects