Re: Moving GiST index constant to parameter

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Thomas Mercieca <tmercieca(at)msn(dot)com>
Cc: "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Moving GiST index constant to parameter
Date: 2017-04-02 15:10:39
Message-ID: 26034.1491145839@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Thomas Mercieca <tmercieca(at)msn(dot)com> writes:
> I have tried introducing a GUC variable (entry in guc.c/config_real) and I have also tried having the parser recognize it (same as fillfactor is recognized), but irrelevant of what I set the value to at run-time, I always get the same unusual index stats (cannot reproduce results) and the following messages in the logfile, suggesting that I broke the function:

A GUC is certainly not the right thing; you should use an index storage
parameter. However, it seems like your problem is independent of that.

> "DEBUG: picksplit method for column 1 of index "idx2243" failed
> HINT: The index is not optimal. To optimize it, contact a developer, or try to use the column as the second one in the CREATE INDEX command.
> STATEMENT: create index idx2243 on geom_table using gist(geom)"

It looks like picksplit would necessarily fail if you tried to use
a ratio >= 0.5, or even very close to 0.5, because you'd be demanding
unachievable perfection of the split.

Beyond that observation, it's hard to say much without seeing what
you changed.

regards, tom lane

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Pavel Stehule 2017-04-02 15:16:06 Re: Variable substitution in psql backtick expansion
Previous Message Emre Hasegeli 2017-04-02 15:05:09 Re: BRIN cost estimate