Received: from localhost (unknown [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id 876862E008D for ; Tue, 18 Mar 2008 22:13:08 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 55558-04 for ; Tue, 18 Mar 2008 22:13:05 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from ag-out-0708.google.com (ag-out-0708.google.com [72.14.246.248]) by postgresql.org (Postfix) with ESMTP id E120C2E008C for ; Tue, 18 Mar 2008 22:13:05 -0300 (ADT) Received: by ag-out-0708.google.com with SMTP id 23so272159agd.5 for ; Tue, 18 Mar 2008 18:13:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:user-agent:mime-version:to:cc:subject:references:in-reply-to:content-type:content-transfer-encoding; bh=BQGojE5qXpX44eS77i7i+oR40zvlpkkxkqqXtTPaCvg=; b=CiB4Q1HwSYC83I4ScPOrAZuKTQoQVcL+IEzyOV6EI57OTpcYasRvwnW8tjk1s2P0MCNrqmFysj7mXuVjSNHpiJy3g/vaCDa7HTAlgMLuDPYQ2esrkvIzDAtlWW5J7zVCzBmPY2BKj3JoDiYkI0cnxMkqj2sFdtk2wOVPtN4TDZs= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=message-id:date:from:user-agent:mime-version:to:cc:subject:references:in-reply-to:content-type:content-transfer-encoding; b=bMB3/SDvnyVkQ0en1rmHYvVvDgz2P4cwiofvmvvLut5G/VV0hbDOh2jRXt6s8OwyHF6a/Fe8zbWBWzza6ydSnEQbcRW/NWCpdnItr7MRtS5WsmsvaAzCUTaBgtfZXARS1HbHWrHAi1ZOn9IYz92ZypRh19UAiIdeL089/Ts0W/k= Received: by 10.100.133.11 with SMTP id g11mr667511and.20.1205889181503; Tue, 18 Mar 2008 18:13:01 -0700 (PDT) Received: from ?10.1.1.5? ( [203.206.174.100]) by mx.google.com with ESMTPS id b19sm4554317ana.18.2008.03.18.18.12.59 (version=TLSv1/SSLv3 cipher=RC4-MD5); Tue, 18 Mar 2008 18:13:00 -0700 (PDT) Message-ID: <47E0680D.6020101@gmail.com> Date: Wed, 19 Mar 2008 12:10:37 +1100 From: Chris User-Agent: Thunderbird 2.0.0.12 (Windows/20080213) MIME-Version: 1.0 To: Mark Steben CC: pgsql-performance@postgresql.org Subject: Re: question on TRUNCATE vs VACUUM FULL References: <00f701c8893b$f9545af0$14010a0a@dei26g028575> In-Reply-To: <00f701c8893b$f9545af0$14010a0a@dei26g028575> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 8bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests=none X-Spam-Level: X-Archive-Number: 200803/390 X-Sequence-Number: 29344 > > So my question is this: Shouldn’t VACUUM FULL clean Table C and reclaim > all its space? You've got concepts mixed up. TRUNCATE deletes all of the data from a particular table (and works in all dbms's). http://www.postgresql.org/docs/8.3/interactive/sql-truncate.html VACUUM FULL is a postgres-specific thing which does work behind the scenes to clean up MVCC left-overs. It does not touch any current data or records in the table, it's purely behind the scenes work. http://www.postgresql.org/docs/current/interactive/sql-vacuum.html The two have completely different uses and nothing to do with each other what-so-ever. -- Postgresql & php tutorials http://www.designmagick.com/