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 771E6D1E14D for ; Thu, 19 Feb 2004 14:58:42 +0000 (GMT) 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 87757-04 for ; Thu, 19 Feb 2004 10:58:48 -0400 (AST) Received: from 216.127.68.117 (unknown [216.127.68.117]) by svr1.postgresql.org (Postfix) with SMTP id C08E3D1E14A for ; Thu, 19 Feb 2004 10:58:38 -0400 (AST) Received: (qmail 23697 invoked from network); 19 Feb 2004 14:57:57 -0000 Received: from m068-240.nv.iinet.net.au (HELO meerkatsoft.com) (203.217.68.240) by localhost with SMTP; 19 Feb 2004 14:57:57 -0000 Message-ID: <4034CF23.80903@meerkatsoft.com> Date: Thu, 19 Feb 2004 23:58:43 +0900 From: Alex User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.3) Gecko/20030312 X-Accept-Language: en-us, en, ja MIME-Version: 1.0 To: pgsql-general@postgresql.org Subject: VACUUM Question Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200402/890 X-Sequence-Number: 57601 Hi, just a few questions on the Vaccum I run a vacuum analyze on the database every night as part of a maintenance job. During the day I have a job that loads 30-70,000 records into two tables (each 30-70k). This job runs 2-3 times a day; the first time mainly inserts, the 2nd, 3rd time mostly updates. Both tables have in the area of 1-3Mio records How reasonable is it to run a Vacuum Analyze before and after the insert/update of the data. Also, I noticed that i get quite some performance improvement if I run a count(*) on the two tables before the insert. Any reasons for that? One more question; on one server the Vacuum Analyze before the insert takes approx. 2min after that the same command takes 15min. I run PG7.3.4 Thanks for any help Alex