Re: Memory usage during vacuum - Mailing list pgsql-general

From Tom Lane
Subject Re: Memory usage during vacuum
Date
Msg-id 13252.1080239898@sss.pgh.pa.us
Whole thread Raw
In response to Re: Memory usage during vacuum  (Shelby Cain <alyandon@yahoo.com>)
Responses Re: Memory usage during vacuum
List pgsql-general
Shelby Cain <alyandon@yahoo.com> writes:
> It still decided to sample 150000 rows.  Am I missing
> something obvious here?  Shouldn't fewer rows be
> sampled when I set the collection target to 1?

The sample size is 300 rows times the largest per-column analysis
target, where default_statistics_target is used if the recorded
per-column setting is -1.  I would say that you have set a target of 500
for at least one of the columns of that table, using ALTER TABLE SET
STATISTICS.  Try this to see which:

select attname, attstattarget from pg_attribute
where attrelid = 'table_name_here'::regclass;

            regards, tom lane

pgsql-general by date:

Previous
From: Jan Wieck
Date:
Subject: Re: 7.4.2 on Solaris 9 - Error
Next
From: Vivek Khera
Date:
Subject: Re: Perl DBIx::SearchBuilder and pg_atoi: zero-length string?