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

Re: docfix - DELETE doesn't affect auto-analyze

From: ITAGAKI Takahiro <itagaki(dot)takahiro(at)oss(dot)ntt(dot)co(dot)jp>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Bruce Momjian <bruce(at)momjian(dot)us>, pgsql-patches(at)postgresql(dot)org
Subject: Re: docfix - DELETE doesn't affect auto-analyze
Date: 2007-07-18 04:18:50
Message-ID: 20070718130849.61B2.ITAGAKI.TAKAHIRO@oss.ntt.co.jp (view raw or flat)
Thread:
Lists: pgsql-patches
Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:

> Bruce Momjian <bruce(at)momjian(dot)us> writes:
> >> -    is compared to the total number of tuples inserted, updated, or deleted
> >> +    is compared to the total number of tuples inserted or updated
> 
> As best I can tell, this description is even further away from the
> actual CVS HEAD behavior than the previous one.  The code is comparing
> against
> 
>         anltuples = tabentry->n_live_tuples + tabentry->n_dead_tuples -
>             tabentry->last_anl_tuples;
> 
> and deletions surely increase n_dead_tuples.

Yes, but they also decrease n_live_tuples;
anltuples is not affected by deletions.

if (isCommit)
{
    tabstat->t_counts.t_new_live_tuples +=
        trans->tuples_inserted - trans->tuples_deleted;
    tabstat->t_counts.t_new_dead_tuples += trans->tuples_deleted;
}

Regards,
---
ITAGAKI Takahiro
NTT Open Source Software Center



In response to

pgsql-patches by date

Next:From: Peter EisentrautDate: 2007-07-18 06:27:16
Subject: Re: execl() sentinel
Previous:From: Alvaro HerreraDate: 2007-07-18 04:17:52
Subject: Re: docfix - DELETE doesn't affect auto-analyze

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