From: | Guillaume Lelarge <guillaume(at)lelarge(dot)info> |
---|---|
To: | Stephen Denne <Stephen(dot)Denne(at)datamail(dot)co(dot)nz> |
Cc: | Melvin Davidson <mdavidson(at)trenstar(dot)com>, pgadmin-support(at)postgresql(dot)org |
Subject: | Re: Count not updated with VACUUM ANALYZE |
Date: | 2008-03-27 00:21:52 |
Message-ID: | 47EAE8A0.6080608@lelarge.info |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgadmin-support |
Stephen Denne a écrit :
>> Melvin Davidson a écrit :
>>> *PgAdmin III 1.8.2***
>>>
>>> I have statistics enabled on my server. However, when I do a VACUUM
>>> ANALYZE on my database, the count [ Rows (counted) ] is set to “not
>>> counted”.
>>>
>>> Now I can right click on the individual tables and select
>> “Count” to
>>> manually update it, but shouldn’t the VACUUM have done that?
>>>
>> Nope. ANALYZE collects some statistics (for example an
>> estimated number
>> of rows on each table... this number is available in pgAdmin
>> under the
>> exact number of rows).
>
> I think Guillaume meant "estimated" rather than "exact" here.
>
Well, I really meant "exact". There's one line for the exact number of
rows (which needs some time to get), and there's one line for the
estimated number (the one that ANALYZE gets).
>> The Count item of the contextual menu does a count(*) on the
>> table. So,
>> it gives you the exact number of rows.
>>
>>> Also, is there an documented (or undocumented) function I
>> can run to
>>> manually update the counts.
>>>
>> No. You really need to select the menu item "Count" to have the exact
>> number of rows.
>
> There is an option under the Query tab named
> "Count rows if estimated less than"
> which you could change to a larger number.
>
Oh yes, you're right about this option. I completely forgot it, thanks.
> I have mine set to 0 as I don't like the delay, and the estimates fill my needs.
>
--
Guillaume.
http://www.postgresqlfr.org
http://dalibo.com
From | Date | Subject | |
---|---|---|---|
Next Message | Dave Page | 2008-03-27 16:07:58 | Re: pgAdmin hang on connection drop/reconnect |
Previous Message | Stephen Denne | 2008-03-27 00:16:03 | Re: Count not updated with VACUUM ANALYZE |