Re: strange error occurs when adding index

Поиск
Список
Период
Сортировка
От Dimitri Fontaine
Тема Re: strange error occurs when adding index
Дата
Msg-id m2bplq1p2w.fsf@hi-media.com
обсуждение исходный текст
Ответ на Re: strange error occurs when adding index  (hubert depesz lubaczewski <depesz@depesz.com>)
Список pgsql-general
hubert depesz lubaczewski <depesz@depesz.com> writes:

> On Fri, Sep 04, 2009 at 05:42:31PM +0800, Juan Backson wrote:
>> When I tried to add the following index, I get some strange error.  Does
>> anyone know what these errors mean and how to fix it?
>> Here is the index query:
>> create index idx_product_items_digits on product_items using gist (digits
>> gist_prefix_range_ops,product_id)
>
> these are not errors, just notices. are you sure you have the latest
> prefix version?

I just realized earlier this week that the pgfoundry main page for
prefix was proposing the very old (as in avoid it) 0.2 version. It's now
fixed to list the current 1.0~rc2 version, which you'll find also in
debian testing and sid:
  http://pgfoundry.org/projects/prefix/
  http://packages.debian.org/search?searchon=sourcenames&keywords=prefix

This version still comes with #define DEBUG (hey, it's a release
candidate) and penalty() is chatty on some cases where it finds that
your prefix ranges are not containing only numbers, because the penalty
computation isn't really verified against the general case... but should
work: you just won a non-numeric-only prefix_range testing ticket :)

Have you got anything to report performance wise?

Given:
>>  __pr_penalty(sa[], a1928901[]) orig->first=0 orig->last=0
>> NOTICE:  __pr_penalty(sa[], 1206323[]) orig->first=0 orig->last=0

Could you report the result of:
  SELECT pr_penalty('sa', 'a1928901'), pr_penalty('sa', '1206323');

If you're happy with performances as is, I'll remove the NOTICE and
Assert(), if not, we'll have to either find a more general algorithm or
limit the accepted inputs.

Regards,
--
dim

В списке pgsql-general по дате отправления:

Предыдущее
От: William Temperley
Дата:
Сообщение: Re: [Q] optmizing postgres for 'single client' / many small queries
Следующее
От: Martin Gainty
Дата:
Сообщение: Re: where clause question