Transactions, tuples, and VACUUM - Mailing list pgsql-admin

From Matt Clark
Subject Transactions, tuples, and VACUUM
Date
Msg-id OAEAKHEHCMLBLIDGAFELAEKFDGAA.matt@ymogen.net
Whole thread Raw
In response to Re: Backup routine  ("scott.marlowe" <scott.marlowe@ihs.com>)
Responses Re: Transactions, tuples, and VACUUM
List pgsql-admin
Morning all, bit of a general question here...

consider:

  begin;
  update a set col1 = 'p' where id = '1';
  update a set col2 = 'q' where id = '1';
  commit;

versus:

  update a set col1 = 'p', col2 = 'q' where id = '1';

Does the first case generate any more dead tuples that will need vacuuming than the second case, or are the two updates
'merged'
when the transaction is committed?  Or is the answer 'sometimes' (I would guess depending on checkpoints)?

Cheers

Matt






pgsql-admin by date:

Previous
From: "mathan"
Date:
Subject: How to test Miscellaneous Functions
Next
From: Tom Lane
Date:
Subject: Re: Transactions, tuples, and VACUUM