Re: partitionning - Mailing list pgsql-general

From Martijn van Oosterhout
Subject Re: partitionning
Date
Msg-id 20050312231833.GA31116@svana.org
Whole thread Raw
In response to Re: partitionning  (Mike Rylander <mrylander@gmail.com>)
Responses Re: partitionning  (Mike Rylander <mrylander@gmail.com>)
Re: partitionning  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
On Sat, Mar 12, 2005 at 08:24:20PM +0000, Mike Rylander wrote:
> There is now way to have PG completely skip the unused partitions.
> However, with an index on the "partitioner" column of each partition
> table PG will basically fall of the end of the index almost
> imediately, and then use an appropiate plan for the useful partitions.
>  It's not the same as Oracle partitioning, but without expicit Planner
> work it can't be.

Note, the planner does have most of the intelligence needed to
determine when it can skip a partition. It has code that can determine
if the intersection of:

Partition constraint:    lower bound < value < upper bound
Query clause:            value [operator] constant

Will be always false or can be true. It's just a matter of getting the
clause to the right place to make it skip...

Have a nice day,
--
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a
> tool for doing 5% of the work and then sitting around waiting for someone
> else to do the other 95% so you can sue them.

Attachment

pgsql-general by date:

Previous
From: Karsten Hilbert
Date:
Subject: Re: Best practices: Handling Daylight-saving time
Next
From: Lonni J Friedman
Date:
Subject: Re: postgresql error