Re: horizontal partition

From: Klint Gore <kg(at)kgb(dot)une(dot)edu(dot)au>
To: Gaetano Mendola <mendola(at)bigfoot(dot)com>
Cc: pgsql-performance(at)postgresql(dot)org
Subject: Re: horizontal partition
Date: 2005-02-03 03:31:35
Message-ID: 42019B1735F.1271KG@129.180.47.120
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On Thu, 03 Feb 2005 02:10:15 +0100, Gaetano Mendola <mendola(at)bigfoot(dot)com> wrote:
> why the index usage is lost if used in that way ?

This is how I interpret it (if anyone wants to set me straight or
improve on it feel free)

Views are implemented as rules.

Rules are pretty much just a macro to the query builder. When it sees
the view, it replaces it with the implementation of the view.

When you join a view to a table, it generates a subselect of the
implementation and joins that to the other table.

So the subselect will generate the entire set of data from the view
before it can use the join to eliminate rows.

I would like a way to make this work better as well. One of my views is
32 joins of the same table (to get tree like data for reports).

klint.

+---------------------------------------+-----------------+
: Klint Gore : "Non rhyming :
: EMail : kg(at)kgb(dot)une(dot)edu(dot)au : slang - the :
: Snail : A.B.R.I. : possibilities :
: Mail University of New England : are useless" :
: Armidale NSW 2351 Australia : L.J.J. :
: Fax : +61 2 6772 5376 : :
+---------------------------------------+-----------------+

In response to

Responses

Browse pgsql-performance by date

  From Date Subject
Next Message Christopher Browne 2005-02-03 03:35:19 Re: High end server and storage for a PostgreSQL OLTP system
Previous Message Josh Berkus 2005-02-03 03:16:08 Re: horizontal partition