Re: Dynamic Partitioning using Segment Visibility Maps

From: Simon Riggs <simon(at)2ndquadrant(dot)com>
To: Markus Schiltknecht <markus(at)bluegap(dot)ch>
Cc: Gokulakannan Somasundaram <gokul007(at)gmail(dot)com>, tomas(at)tuxteam(dot)de, Robert Treat <xzilla(at)users(dot)sourceforge(dot)net>, pgsql-hackers(at)postgresql(dot)org, Andrew Sullivan <ajs(at)crankycanuck(dot)ca>
Subject: Re: Dynamic Partitioning using Segment Visibility Maps
Date: 2008-01-09 14:47:48
Message-ID: 1199890068.4266.279.camel@ebony.site
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sun, 2008-01-06 at 11:39 +0100, Markus Schiltknecht wrote:

> I think this has to do with SE not being of much use for index scans.

Hmmm. I think it fits rather neatly with BitmapIndexScans. It would be
easy to apply the index condition and/or filters to see which segments
are excluded and then turn off bits in the bitmap appropriately.

Not fully sure about IndexScans yet. I don't think it would be worth
trying to apply SE until we estimated we would return say 100 rows. It
needs to be able to work without slowing down the common path.

> Or
> put it another way: SE is an optimization for sequential scans. For
> tables where it works well, it could possibly replace the index entirely.

True

> Without the index, you would rely on SE to always be able to exclude
> enough segments, so that the seq scan is less expensive than an index
> scan with the following table lookups.

It would have to be a very fat index scan for so large a table...

--
Simon Riggs
2ndQuadrant http://www.2ndQuadrant.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Gokulakannan Somasundaram 2008-01-09 14:49:38 Re: Some ideas about Vacuum
Previous Message Simon Riggs 2008-01-09 14:34:30 Re: Dynamic Partitioning using Segment Visibility Maps