Re: Problems with index-scan on regexp in 8.1
От | Martijn van Oosterhout |
---|---|
Тема | Re: Problems with index-scan on regexp in 8.1 |
Дата | |
Msg-id | 20051107131313.GC841@svana.org обсуждение исходный текст |
Ответ на | Problems with index-scan on regexp in 8.1 (Lars Kanis <kanis@comcard.de>) |
Ответы |
Re: Problems with index-scan on regexp in 8.1
|
Список | pgsql-hackers |
On Mon, Nov 07, 2005 at 07:50:20AM +0100, Lars Kanis wrote: > We're using Postgres 8.0.2 on SuSE10.0 (64-Bit). Tests on 8.1 beta 4 have > shown no problems but this one: > > SELECT * FROM mitglieder WHERE lower(vorname::text)='lars' > > does a bitmap-index-scan like this: Check your locales. For non-ASCII locales the normal shortcuts for regex optimisation can't apply. Evidently your old installation uses a different locale from your new one. You should be able to make this work by declaring your index with "text_pattern_ops", like so: CREATE INDEX myindex ON mytable(mycolumn text_pattern_ops); Hope this helps, -- Martijn van Oosterhout <kleptog@svana.org> http://svana.org/kleptog/ > Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a > tool for doing 5% of the work and then sitting around waiting for someone > else to do the other 95% so you can sue them.
В списке pgsql-hackers по дате отправления: