| From: | Merlin Moncure <mmoncure(at)gmail(dot)com> |
|---|---|
| To: | Leonardo Francalanci <m_lists(at)yahoo(dot)it> |
| Cc: | Divakar Singh <dpsmails(at)yahoo(dot)com>, pgsql-performance(at)postgresql(dot)org |
| Subject: | Re: Postgres insert performance and storage requirement compared to Oracle |
| Date: | 2010-10-26 15:41:59 |
| Message-ID: | AANLkTinaW3ZtGJbzgAARG0WfAOJxSPAbdVAZa6X_2dh+@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers pgsql-performance |
On Tue, Oct 26, 2010 at 11:08 AM, Leonardo Francalanci <m_lists(at)yahoo(dot)it> wrote:
>> temp tables are not wal logged or
>> synced. Periodically they can be flushed to a permanent table.
>
>
> What do you mean with "Periodically they can be flushed to
> a permanent table"? Just doing
>
> insert into tabb select * from temptable
>
yup, that's exactly what I mean -- this will give you more uniform
insert performance (your temp table doesn't even need indexes). Every
N records (say 10000) you send to permanent and truncate the temp
table. Obviously, this is more fragile approach so weigh the
pros/cons carefully.
merlin
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Alvaro Herrera | 2010-10-26 15:52:38 | Re: xlog.c: WALInsertLock vs. WALWriteLock |
| Previous Message | Boszormenyi Zoltan | 2010-10-26 15:34:56 | Re: plan time of MASSIVE partitioning ... |
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Josh Berkus | 2010-10-26 20:54:07 | Re: CPUs for new databases |
| Previous Message | Christian Elmerot | 2010-10-26 15:23:34 | Re: CPUs for new databases |