Jack Douglas wrote:
> > in 9.4, GIN indexes are pretty close to this already
>
> Do I understand correctly that BRIN indexes will be even closer to this?
>
Yeah, in a way. You could say they are closer from the opposite end.
There is one index tuple in a BRIN index for each page range (contiguous
set of pages); each index tuple contains a "summary" of what in that
page range. There are no exact entries. If the values are randomly
scattered, the index is useless; all page ranges will have to be scanned
for possibly matching tuples. If the values are perfectly clustered,
the index is optimal because you scan the minimal set of pages.
--
Álvaro Herrera http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services