Re: optimising UNION performance - Mailing list pgsql-general

From Tom Lane
Subject Re: optimising UNION performance
Date
Msg-id 27811.1156776394@sss.pgh.pa.us
Whole thread Raw
In response to Re: optimising UNION performance  (Alban Hertroys <alban@magproductions.nl>)
Responses Re: optimising UNION performance  (Rafal Pietrak <rafal@zorro.isa-geek.com>)
List pgsql-general
Alban Hertroys <alban@magproductions.nl> writes:
> There's practically no difference between SELECT 1 FROM ... and SELECT *
> FROM ...; the only added costs (AFAIK) are for actually fetching the
> column values and such. Pretty cheap operations.

You're both glossing over exactly the wrong thing, particularly seeing
that Rafal appears to be using 8.0 or older which hasn't got 8.1's
significant reductions in targetlist evaluation costs.

            regards, tom lane

pgsql-general by date:

Previous
From: "Harpreet Dhaliwal"
Date:
Subject: Re: Perl language creation failed
Next
From: Tom Lane
Date:
Subject: Re: Perl language creation failed