View performance degraded between 8.1 and 8.3 - Mailing list pgsql-performance

From Mark Roghelia
Subject View performance degraded between 8.1 and 8.3
Date
Msg-id EMEWEMEW2_DELIMl19GKc89898453881991060337b2,mroghelia@topsailtech.com,ABA4D918-D3A2-4DFE-8B35-DB
Whole thread Raw
Responses Re: View performance degraded between 8.1 and 8.3
List pgsql-performance
I've got an application that pulls stock information from the web and
performs a bunch of calculations on them.  There is a "stock" table
and then for convenience I've got a view called "stock_calculations".
This view is defined as a stock id column coupled with 30-some
calculated columns.  Some of these columns are computationally intense
and are delegated to functions.

If I ever "select * from stock_calculations", the query is
understandable pretty slow, since it has to do every one of the
calculations for each stock.  However, in 8.1, if I only selected a
couple of specific columns from the view, it ran very quickly.  I
assumed that the database did not bother calculating all the other
columns it didn't need.

Unfortunately, I've recently upgraded to 8.3 and found that selecting
a single column from this view has now become as slow as selecting all
of them.

I'm wondering if there is any thing that I can do about this short of
downgrading to 8.1?  Are there any configuration parameters that
effect this behavior?

Thanks,

Mark


pgsql-performance by date:

Previous
From: justin
Date:
Subject: Re: explanation of some configs
Next
From: Tom Lane
Date:
Subject: Re: View performance degraded between 8.1 and 8.3