Re: VACUUM FULL vs dropped columns

2018-03-10 Thread Andrew Dunstan
On Sun, Mar 11, 2018 at 9:49 AM, Tom Lane wrote: > Andrew Dunstan writes: >> Why does VACUUM FULL cause the size of this table with a single >> dropped column (1 out of 1000) cause the table size to double? > > VACUUM FULL will rewrite the tuples with a null bitmap where they > had none before (c

Re: VACUUM FULL vs dropped columns

2018-03-10 Thread Tom Lane
Andrew Dunstan writes: > Why does VACUUM FULL cause the size of this table with a single > dropped column (1 out of 1000) cause the table size to double? VACUUM FULL will rewrite the tuples with a null bitmap where they had none before (cf reform_and_rewrite_tuple). That's only a rather marginal

VACUUM FULL vs dropped columns

2018-03-10 Thread Andrew Dunstan
While doing some testing I noticed this, which seems somewhat perverse: create table t(); insert into t select from generate_series(1,1); select 'alter table t ' || string_agg(' add column c'||x::text||' int default ' ||x::text,',') from generate_series(1,1000) x \gexec create table t_dropped