Skip site navigation (1) Skip section navigation (2)

Re: Much Ado About COUNT(*)

From: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "Jonah H(dot) Harris" <jharris(at)tvi(dot)edu>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Much Ado About COUNT(*)
Date: 2005-01-13 04:57:56
Message-ID: 200501130457.j0D4vuQ28534@candle.pha.pa.us (view raw or flat)
Thread:
Lists: pgsql-announcepgsql-hackerspgsql-patches
Tom Lane wrote:
> Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:
> > My basic idea was to keep a status bit on each index entry telling it if
> > a previous backend looked at the heap and determined it was valid.
> 
> Even if you could track the tuple's committed-good status reliably,
> that isn't enough under MVCC.  The tuple might be committed good, and
> seen that way by some other backend that set the bit, and yet it's not
> supposed to be visible to your older transaction.  Or the reverse at
> tuple deletion.

I mentioned that:

> (Oh, and you could only update the bit when all active transactions
> are newer than the creation transaction so we know they should all see
> it as visible.)

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman(at)candle(dot)pha(dot)pa(dot)us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

In response to

Responses

pgsql-announce by date

Next:From: Tom LaneDate: 2005-01-13 05:06:38
Subject: Re: Much Ado About COUNT(*)
Previous:From: Tom LaneDate: 2005-01-13 04:54:52
Subject: Re: Much Ado About COUNT(*)

pgsql-hackers by date

Next:From: Tom LaneDate: 2005-01-13 05:06:38
Subject: Re: Much Ado About COUNT(*)
Previous:From: Tom LaneDate: 2005-01-13 04:54:52
Subject: Re: Much Ado About COUNT(*)

pgsql-patches by date

Next:From: Tom LaneDate: 2005-01-13 05:06:38
Subject: Re: Much Ado About COUNT(*)
Previous:From: Tom LaneDate: 2005-01-13 04:54:52
Subject: Re: Much Ado About COUNT(*)

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group