Search Postgresql Archives

Re: Vacuum and inserts

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Michael Fuhr <mike@xxxxxxxx> writes:
> On Wed, Jun 18, 2008 at 12:29:46PM -0700, Mark Wilden wrote:
>> My theory is that since there are no outdated nor deleted rows, VACUUM
>> doesn't do anything.

> Rolled back transactions on an insert-only table can leave behind
> dead rows.  Also, even if the table never has dead rows you still
> have to vacuum periodically to prevent transaction ID wraparound.

Another reason why you might want to vacuum after a bulk insertion
is to get all the commit hint bits set, rather than leaving that
overhead to be done by live queries.

In 8.4 there might be yet another reason, if you have a GIN index
on the table: Teodor is talking about postponing some of the GIN
insertion work to VACUUM ...

			regards, tom lane


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux