Re: Method of building views - Mailing list pgsql-general

From Bruno Wolff III
Subject Re: Method of building views
Date
Msg-id 20050222061612.GA3623@wolff.to
Whole thread Raw
In response to Method of building views  ("Richard Crawley" <richard.crawley@quadronservices.co.uk>)
List pgsql-general
On Sat, Feb 19, 2005 at 13:30:49 -0000,
  Richard Crawley <richard.crawley@quadronservices.co.uk> wrote:
>
> I suppose what I'm doing is building some quite large, complicated views.
> Now, thus far I haven't had much choice, and the temp tables do help
> debugging. But this approach doesn't allow the dbase any optimising and
> these long chains of queries are quite fragile.
>
> My question is whether there are better ways of doing it. I could probably
> (hopefully) convert it into one mega query, which would allow the dbase the
> opportunity to optimise. My worry is that it would be a dense tangle of
> things and hence difficult to maintain/explain.

Using the views modularly should help keep things maintainable and allow
for optimization. Roughly there would be a view corresponding to each
temporary table in your previous way of doing things.

pgsql-general by date:

Previous
From: Shachar Shemesh
Date:
Subject: Re: ADO and timestamp/date errors
Next
From: sid tow
Date:
Subject: Performance check using COPY commands