Re: how could select id=xx so slow? - Mailing list pgsql-performance

From Daniel Farina
Subject Re: how could select id=xx so slow?
Date
Msg-id CAAZKuFZn3gXpr-b60+b_A6XqX8Do6P8hL770bcTg9BaLT0mBFw@mail.gmail.com
Whole thread Raw
In response to how could select id=xx so slow?  (Yan Chunlu <springrider@gmail.com>)
List pgsql-performance
On Thu, Jul 5, 2012 at 11:17 PM, Yan Chunlu <springrider@gmail.com> wrote:
> I have grabbed one day slow query log and analyzed it by pgfouine, to my
> surprise, the slowest query is just a simple select statement:
>
> select diggcontent_data_message.thing_id, diggcontent_data_message.KEY,
> diggcontent_data_message.value, diggcontent_data_message.kind FROM
> diggcontent_data_message WHERE diggcontent_data_message.thing_id = 3570882;
>
>
> where thing_id is the primary key,  guess how long it takes?
>
> 754.61 seconds!!

Is it possible that the size of the tuple is enormous?  Because one
area where I've noticed EXPLAIN ANALYZE blows away normal performance
is when a lot of the work would be in reassembling, decompressing
(collectively: de-TOASTING) and sending the data.

Even then, that time seems excessive...but something to think about.

--
fdr

pgsql-performance by date:

Previous
From: Yan Chunlu
Date:
Subject: how could select id=xx so slow?
Next
From: Craig Ringer
Date:
Subject: Re: how could select id=xx so slow?