Re: Table and Index compression

From: Sam Mason <sam(at)samason(dot)me(dot)uk>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Table and Index compression
Date: 2009-08-07 14:29:06
Message-ID: 20090807142906.GG5407@samason.me.uk
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Aug 07, 2009 at 04:17:18PM +0200, Pierre Frrrdddric Caillaud wrote:
> I'm answering my own question : at the beginning of the run, postgres
> creates a 800MB temporary file, then it fills the table, then deletes the
> temp file.
> Is this because I use generate_series to fill the test table ?

Doh, yes. A function's result is written to temp location first and
then read back again once the function returns success. You'll have
more luck if you do:

SELECT now() + '1 sec'::INTERVAL, (1+random()*99998),
random()*10000000,n+random()*10000, n+random()*1000, n
FROM (
SELECT generate_series( 1, 60000000 )) x(n);

--
Sam http://samason.me.uk/

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2009-08-07 14:36:32 Re: include/commands/version.h is not used
Previous Message Tom Lane 2009-08-07 14:25:29 Re: Re: [Pg-migrator-general] Composite types break pg_migrated tables