On 07/07/2015 06:28 AM, Marc Mamin wrote: > Sure, but on the other hand, they are so small and quick to build > that they seem to be a good alternative when other index types are too > costly, > even if theses indexes can't deal well with all data ranges passed as query > condition. > > Hence it would be fine if the planner could reject these indexes in the bad > cases.
Oh, sorry! I didn't realize that the planner was using the BRIN index even when it was useless; your email wasn't clear. The problem here is that the usefulness of BRIN indexes as a cost calculation should take correlation into account, heavily. Can we do that? Is correlation even part of the index costing method now? How accurate are our correlation estimates? -- Josh Berkus PostgreSQL Experts Inc. http://pgexperts.com -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers