X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 865B653838 for ; Thu, 7 Apr 2005 13:37:56 +0100 (BST) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 53570-10 for ; Thu, 7 Apr 2005 12:37:48 +0000 (GMT) Received: from anchor-post-36.mail.demon.net (anchor-post-36.mail.demon.net [194.217.242.86]) by svr1.postgresql.org (Postfix) with ESMTP id C8DD553821 for ; Thu, 7 Apr 2005 13:37:47 +0100 (BST) Received: from mwynhau.demon.co.uk ([193.237.186.96] helo=mainbox.archonet.com) by anchor-post-36.mail.demon.net with esmtp (Exim 4.42) id 1DJWGb-000Pn8-Lg; Thu, 07 Apr 2005 12:37:49 +0000 Received: from [192.168.1.17] (client17.archonet.com [192.168.1.17]) by mainbox.archonet.com (Postfix) with ESMTP id 98A6E17C06; Thu, 7 Apr 2005 13:37:46 +0100 (BST) Message-ID: <4255299B.3080101@archonet.com> Date: Thu, 07 Apr 2005 13:37:47 +0100 From: Richard Huxton User-Agent: Mozilla Thunderbird 1.0 (X11/20041206) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Sean Davis Cc: 'PostgreSQL' , dpandey@secf.com Subject: Re: Table PARTITION References: <20050407114136.17B7E53AA5@svr1.postgresql.org> <42552244.5050603@archonet.com> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.059 tagged_above=0 required=5 tests=AWL, FORGED_RCVD_HELO X-Spam-Level: X-Archive-Number: 200504/77 X-Sequence-Number: 20970 Sean Davis wrote: > This is a totally selfish question, but IF someone has a few minutes, > could he/she explain why table partitioning is such an important tool? Say you have a large log-table, you could partition it by month. If most queries only search the last month or two, a lot of your partitioned data could be moved to cheaper/slower disks (via tablespaces). After (say) 24 months, you can start dropping the oldest partitions, and this should take place without affecting any other partitions. How you partition your data depends on how you plan to access it. If you don't query your log-tables by date there's not much point in partitioning by date. -- Richard Huxton Archonet Ltd