Re: Various performance questions - Mailing list pgsql-performance

From Greg Stark
Subject Re: Various performance questions
Date
Msg-id 87n0bmwl7w.fsf@stark.dyndns.tv
Whole thread Raw
In response to Re: Various performance questions  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Various performance questions  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-performance
Tom Lane <tgl@sss.pgh.pa.us> writes:

> Greg is correct.  int8 is a pass-by-reference datatype

Just to keep the conversation on track. the evidence from this particular post
seems to indicate that my theory was wrong and the overhead for count(*) is
_not_ a big time sink. It seems to be at most 10% and usually less. A simple
"select 1 from tab" takes nearly as long.

I'm still puzzled why the times on these are so different when the latter
returns fewer records and both are doing sequential scans:

 select 1 from tab

 select 1 from tab where a < 1000

--
greg

pgsql-performance by date:

Previous
From: Tom Lane
Date:
Subject: Re: Various performance questions
Next
From: Greg Stark
Date:
Subject: Re: Various performance questions