Re: Re: invalid memory alloc request size 2147483648 using toode LIKE 'ä%' - Mailing list pgsql-general

From Tom Lane
Subject Re: Re: invalid memory alloc request size 2147483648 using toode LIKE 'ä%'
Date
Msg-id 16987.1185426319@sss.pgh.pa.us
Whole thread Raw
In response to Re: invalid memory alloc request size 2147483648 using toode LIKE 'ä%'  ("Andrus" <kobruleht2@hot.ee>)
List pgsql-general
"Andrus" <kobruleht2@hot.ee> writes:
>> This looks like a problem already reported, and patched here:
>> http://archives.postgresql.org/pgsql-committers/2007-05/msg00088.php
>> but that fix hasn't made it into any released version yet.

> Thank you.

> I fixed it in my application by changing index to upper() instead of lower :

> CREATE UNIQUE INDEX toode_toode_unique_pattern_idx1
>   ON firma1.toode
>   USING btree
>   (upper(toode::text) text_pattern_ops);

> and using

> SELECT * FROM firma1.toode WHERE upper(toode)  LIKE '�%'

> Will this work OK ?

I think you're probably just dodging one symptom by exposing yourself
to others :-(.  Maybe you will hit some other cases, or maybe not;
there's not enough detail here to guess.

We are overdue for another set of patch releases, but right now the core
committee is trying to focus on pushing 8.3 to beta release readiness.
I hope we can come up for air from that, and push out some back-branch
updates, in the second half of August.

            regards, tom lane

pgsql-general by date:

Previous
From: "Pavel Stehule"
Date:
Subject: Re: C function problem with 8.2.4
Next
From: Naz Gassiep
Date:
Subject: Re: using Tsearch2 for chemical text