Re: BUG #1671: Long interval string representation rejected - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #1671: Long interval string representation rejected
Date
Msg-id 28528.1116475685@sss.pgh.pa.us
Whole thread Raw
In response to Re: BUG #1671: Long interval string representation rejected  (Neil Conway <neilc@samurai.com>)
Responses Re: BUG #1671: Long interval string representation rejected  (Neil Conway <neilc@samurai.com>)
List pgsql-bugs
Neil Conway <neilc@samurai.com> writes:
>> Perhaps it would work to downcase just one token at a time, so that
>> the max buffer length equals the max acceptable token?

> Not sure I follow you.

I believe that the reason for the local buffer is to hold a downcased
version of the input, which we can compare to the all-lower-case tables
of relevant keywords.  So plan A for fixing it is to downcase and
compare one token at a time, instead of downcasing the whole string
at once.

Plan B is to make the token comparison routines case-insensitive
themselves, so that there's no need for a temporary copy of the input.

Probably someone can think of plans C and D too ... I don't have any
strong allegiance to any one way to fix it.

            regards, tom lane

pgsql-bugs by date:

Previous
From: Neil Conway
Date:
Subject: Re: BUG #1671: Long interval string representation rejected
Next
From: Neil Conway
Date:
Subject: Re: BUG #1671: Long interval string representation rejected