X-Original-To: pgsql-general-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id CBD35D1C938 for ; Mon, 24 May 2004 14:17:38 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (neptune.hub.org [200.46.204.2]) (amavisd-new, port 10024) with ESMTP id 19750-09 for ; Mon, 24 May 2004 14:17:17 -0300 (ADT) Received: from joeconway.com (66-146-172-86.skyriver.net [66.146.172.86]) by svr1.postgresql.org (Postfix) with ESMTP id 8464AD1BC59 for ; Mon, 24 May 2004 14:17:14 -0300 (ADT) Received: from [206.19.64.3] (account jconway HELO [172.16.211.175]) by joeconway.com (CommuniGate Pro SMTP 4.1.8) with ESMTP-TLS id 1720844; Mon, 24 May 2004 10:10:25 -0700 Message-ID: <40B23BAB.8090007@joeconway.com> Date: Mon, 24 May 2004 11:15:07 -0700 From: Joe Conway User-Agent: Mozilla Thunderbird 0.6 (Windows/20040502) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Greg Stark Cc: David Garamond , pgsql-general@postgresql.org Subject: Re: how many record versions References: <40AFAD9F.6000104@zara.6.isreserved.com> <40B0D230.6030803@zara.6.isreserved.com> <87vfimq114.fsf@stark.xeocode.com> <40B1904A.3090307@zara.6.isreserved.com> <87pt8tq5ut.fsf@stark.xeocode.com> In-Reply-To: <87pt8tq5ut.fsf@stark.xeocode.com> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at postgresql.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests= X-Spam-Level: X-Archive-Number: 200405/739 X-Sequence-Number: 61173 Greg Stark wrote: > Well this was actually under Oracle, but I can extrapolate to Postgres given > my experience. > > The idea tool for the job is a feature that Postgres has discussed but hasn't > implemented yet, "partitioned tables". Under Oracle with partitioned tables we > were able to drop entire partitions virtually instantaneously. It also made > copying the data out to near-line backups much more efficient than index > scanning as well. I think you can get a similar effect by using inherited tables. Create one "master" table, and then inherit individual "partition" tables from that. Then you can easily create or drop a "partition", while still being able to query the "master" and see all the rows. HTH, Joe