pg.ddx.io  pgsql-performance@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Nickolay <nitro@zhukcity.ru>
To: Kenneth Marshall <ktm@rice.edu>
Cc: pgsql-performance@postgresql.org
Subject: Re: PG optimization question
Date: Sat, 09 Jan 2010 15:59:08 +0300
Message-ID: <4B487D9C.9020507@zhukcity.ru> (raw)
In-Reply-To: <20100109124646.GA8123@it.is.rice.edu>
References: <4B485975.70506@zhukcity.ru>
	<2f4958ff1001090418i78dee992t5ff2d78a54187c07@mail.gmail.com>
	<4B4879A0.2060703@zhukcity.ru>
	<20100109124646.GA8123@it.is.rice.edu>

That may help with the queries speed (not a problem now), but we'll then 
have to add UNION statement for daily staging table for other 5% of 
requests, right? And there would be a moment when daily message is in 
archive table AND in daily table (while transferring from daily table to 
archive).
Our main problem is in blocking when doing DELETE (app sometimes freezes 
for a long time), and also we have to do VACUUM on live table, which is 
not acceptable in our app.

Thanks for your reply, I was kinda worried about number of partitions 
and how this would affect PG query execution speed.

Kenneth Marshall wrote:
>> Oh, btw, 95% of queries are searching rows for current date (last 24 
>> hours).
>>     
>
> You may want to use a daily staging table and then flush to the 
> monthly archive tables at the end of the day.
>
>   



view thread (14+ messages)  latest in thread

Message-ID: <4B487D9C.9020507@zhukcity.ru>
Permalink:  ../4B487D9C.9020507@zhukcity.ru/
Also on:    postgresql.org/message-id/4B487D9C.9020507@zhukcity.ru

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-performance@postgresql.org
  Cc: nitro@zhukcity.ru, ktm@rice.edu
  Subject: Re: PG optimization question
  In-Reply-To: <4B487D9C.9020507@zhukcity.ru>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox