Re: Views - Under the Hood

From: Terry Lee Tucker <terry(at)chosen-ones(dot)org>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: Views - Under the Hood
Date: 2010-11-04 19:24:44
Message-ID: 201011041524.44661.terry@chosen-ones.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Thursday, November 04, 2010 15:03:49 Scott Marlowe wrote:
> On Thu, Nov 4, 2010 at 12:43 PM, Terry Lee Tucker <terry(at)chosen-ones(dot)org>
wrote:
> > Greetings:
> >
> > Lately, I've begun using views quite often especially when queries for
> > various reports, etc. become complicated. I am now wondering if there is
> > a price to pay in terms of overhead for this. In truth, I don't really
> > understand how a view works. I know that it takes on many of the
> > attributes of a table, but is it a table? Is the data pulled together
> > when one selects from the view or is it maintained as a table all along.
> > Guidance to the ignorant appreciated...
>
> In pgsql a view is actually a rule that fires off the original query
> for you. So it's a simple wrapper, and is the same, for the most
> part, as simply typing in the original query again. So, it's pretty
> simple, and there's no real overhead to worry about.

Thank you Scott! This is exactly what I needed to know...

--
Terry Lee Tucker
tel: (336) 372-5432; cell: (336) 404-6897
terry(at)chosen-ones(dot)org

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Chris Browne 2010-11-04 19:58:35 Re: Views - Under the Hood
Previous Message Scott Marlowe 2010-11-04 19:03:49 Re: Views - Under the Hood