X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.2]) by svr1.postgresql.org (Postfix) with ESMTP id 6150CD1BCA7 for ; Thu, 20 May 2004 11:19:56 -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 55916-06 for ; Thu, 20 May 2004 11:19:39 -0300 (ADT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by svr1.postgresql.org (Postfix) with ESMTP id 66574D1B171 for ; Thu, 20 May 2004 11:19:29 -0300 (ADT) Received: from news.hub.org (news.hub.org [200.46.204.72]) by news.hub.org (8.12.9/8.12.9) with ESMTP id i4KEJSSx026707 for ; Thu, 20 May 2004 14:19:28 GMT (envelope-from news@news.hub.org) Received: (from news@localhost) by news.hub.org (8.12.9/8.12.9/Submit) id i4KDuQLY022013 for pgsql-admin@postgresql.org; Thu, 20 May 2004 13:56:26 GMT X-Abuse-Report: abuse@teranews.com Message-ID: Date: Thu, 20 May 2004 13:48:34 GMT Lines: 20 From: Jeff Boes User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7b) Gecko/20040421 X-Accept-Language: en-us, en MIME-Version: 1.0 X-Newsgroups: comp.databases.postgresql.admin Subject: Table maintenance: order of operations important? Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit To: pgsql-admin@postgresql.org 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/214 X-Sequence-Number: 13530 We have a number of tables from which we expire (delete) rows nightly. Is there any value to ordering the operations, in terms of either table physical organization or elapsed time? E.g., DELETE FROM foo WHERE date_expires < now(); VACUUM ANALYZE foo; CLUSTER foo; REINDEX TABLE foo; How would you choose to order these (under 7.4.x) for fastest turn-around? Does it matter? -- It may not always be easy, convenient, or politically correct to stand for truth and right, but it is the right thing to do. Always. ________ --M. Russell Ballard Jeffery Boes <>< mur@qtm.net