Re: [v9.2] make_greater_string() does not return a string in some cases

From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Marcin Mańk <marcin(dot)mank(at)gmail(dot)com>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Kyotaro HORIGUCHI <horiguchi(dot)kyotaro(at)oss(dot)ntt(dot)co(dot)jp>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: [v9.2] make_greater_string() does not return a string in some cases
Date: 2011-09-26 10:52:23
Message-ID: 1317034343.1759.13.camel@fsopti579.F-Secure.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs pgsql-hackers

On fre, 2011-09-23 at 20:35 +0300, Marcin Mańk wrote:
> One idea:
> col like 'foo%' could be translated to col >= 'foo' and col <= foo || 'zzz' , where 'z' is the largest possible character. This should be good enough for calculating stats.
>
> How to find such a character, i do not know.

That's what makes this so difficult.

If we knew the largest character, we could probably also find the
largest-1, largest-2, etc. characters and determine the total order of
everything.

In response to

Responses

Browse pgsql-bugs by date

  From Date Subject
Next Message Robert Haas 2011-09-26 13:40:46 Re: BUG #6213: COPY does not work as expected in a plpgsql function
Previous Message YAMAMOTO Takashi 2011-09-26 10:15:48 bug in plancache.c

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2011-09-26 10:55:12 Re: Is there any plan to add unsigned integer types?
Previous Message Peter Eisentraut 2011-09-26 10:45:54 Re: unite recovery.conf and postgresql.conf