Re: 9.5 alpha: some small comments on BRIN and btree_gin

From: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
To: Marc Mamin <M(dot)Mamin(at)intershop(dot)de>
Cc: "'pgsql-hackers(at)postgresql(dot)org'" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: 9.5 alpha: some small comments on BRIN and btree_gin
Date: 2015-07-07 02:30:24
Message-ID: 20150707023024.GV3289@postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Marc Mamin wrote:

> - BRIN cost: I've made a silly test, where all distinct values exist in all BRIN page ranges:
>
> INSERT into tbrin_1 (cat_id, ....) SELECT s%20, ... FROM generate_series(1,3000000 )s;
> CREATE INDEX cat_brin_1 on tbrin_1 using BRIN (cat_id)with (pages_per_range=64);
> SELECT * from tbrin_1 WHERE cat_id=10;
> http://explain.depesz.com/s/9YQR
>
> There seems to be no "fence" against useless BRIN indexes that would allow a fallback on a table scan.
> But the time overhead remind small :)

Hmm, I guess the costing function for brin could stand some improvement.
Clearly we're not covering all bases.

--
Álvaro Herrera http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Josh Berkus 2015-07-07 03:51:32 Re: Support for N synchronous standby servers - take 2
Previous Message Michael Paquier 2015-07-07 01:55:09 Re: 9.5 alpha: some small comments on BRIN and btree_gin