Re: unlogged tables - Mailing list pgsql-performance

From Pierre C
Subject Re: unlogged tables
Date
Msg-id op.v5ysw1d3eorkce@apollo13
Whole thread Raw
In response to Re: unlogged tables  ("Anibal David Acosta" <aa@devshock.com>)
List pgsql-performance
> My table is a statistics counters table, so I can live with a partial
> data
> loss, but not with a full data loss because many counters are weekly and
> monthly.
>
> Unlogged table can increase speed, this table has about 1.6 millions of
> update per hour, but unlogged with a chance of loss all information on a
> crash are not a good idea for this.

You could use an unlogged table for hourly updates, and periodically,
accumulate those counters to a (logged) daily/weekly table...

The hourly table could be rebuilt by examining only 1 hour's worth of
data, so it isn't too much of a problem if it's lost. The other tables
would get much less updates.

pgsql-performance by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: pg_upgrade
Next
From: Thiago Godoi
Date:
Subject: Re: Intersect/Union X AND/OR