Re: Auto creation of Partitions

From: "Simon Riggs" <simon(at)2ndquadrant(dot)com>
To: "Luke Lonergan" <LLonergan(at)greenplum(dot)com>
Cc: "NikhilS" <nikkhils(at)gmail(dot)com>, "Shane Ambler" <pgsql(at)sheeky(dot)biz>, "Zeugswetter Andreas ADI SD" <ZeugswetterA(at)spardat(dot)at>, "Peter Eisentraut" <peter_e(at)gmx(dot)net>, <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Auto creation of Partitions
Date: 2007-03-09 13:54:58
Message-ID: 1173448499.3641.274.camel@silverbirch.site
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, 2007-03-09 at 07:40 -0500, Luke Lonergan wrote:

> What happens to the data when the function is dropped or replaced?
>
Well, that wouldn't happen because you build in a dependency.

I'm not working on this, so don't expect lots of detail. The idea is
essentially to implement things the way SQLServer does it.

The function would need some care. It might even need a function that
writes a function.

e.g.
CreateRangePartitionFunction('{date1,date2,date3}', funcname);
ReplaceRangePartitionFunction('{date1,date2,date3}', funcname);

which would then give a properly designed function called funcname to be
used for partitioning, which would include tests to make sure a
partition wasn't inadvertently excluded from the list of existing
partitions of any table that used it.

--
Simon Riggs
EnterpriseDB http://www.enterprisedb.com

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Simon Riggs 2007-03-09 13:55:48 Interaction of PITR backups and Bulk operations avoiding WAL
Previous Message Csaba Nagy 2007-03-09 13:15:18 Re: CLUSTER and MVCC