Re: Possible to improve query plan?

From: Tom Lane
Subject: Re: Possible to improve query plan?
Date: ,
Msg-id: 9658.1295890414@sss.pgh.pa.us
(view: Whole thread, Raw)
In response to: Re: Possible to improve query plan?  ("Kevin Grittner")
Responses: Re: Possible to improve query plan?  ("Kevin Grittner")
List: pgsql-performance

Tree view

Possible to improve query plan?  (Jeremy Palmer, )
   Re: Possible to improve query plan?  (Andy Colson, )
    Re: Possible to improve query plan?  (Jeremy Palmer, )
   Re: Possible to improve query plan?  ("Ing. Marcos Ortiz Valmaseda", )
    Re: Possible to improve query plan?  (Jeremy Palmer, )
   Re: Possible to improve query plan?  ("Kevin Grittner", )
    Re: Possible to improve query plan?  (Robert Haas, )
     Re: Possible to improve query plan?  ("Kevin Grittner", )
      Re: Possible to improve query plan?  (Tom Lane, )
       Re: Possible to improve query plan?  ("Kevin Grittner", )
        Re: Possible to improve query plan?  (Jeremy Palmer, )
         Re: Possible to improve query plan?  ("Kevin Grittner", )
          Re: Possible to improve query plan?  (Cédric Villemain, )
         Re: Possible to improve query plan?  ("Kevin Grittner", )
          Re: Possible to improve query plan?  (Jeremy Palmer, )
     Re: Possible to improve query plan?  (Tom Lane, )

"Kevin Grittner" <> writes:
> Robert Haas <> wrote:
>> But isn't 13.5 seconds awfully slow to scan 149557 rows?  The sort
>> is sorting 23960kB.  Dividing that by 149557 rows gives ~169
>> bytes/per row

> You're right.  I would expect 9 ms as per tuple as a worst case if
> it doesn't need to go to TOAST data.  Caching, multiple rows per
> page, or adjacent pages should all tend to bring it down from there.
> How does it get to 90 ms per row with rows that narrow?

Um, that looks like 90 usec per row, not msec.

            regards, tom lane


pgsql-performance by date:

From: Jeremy Palmer
Date:
Subject: Re: Possible to improve query plan?
From: "Kevin Grittner"
Date:
Subject: Re: Possible to improve query plan?