On Wed, Sep 9, 2015 at 7:53 PM, Charles Sheridan <cesh...@swbell.net> wrote:
> When there are several views defined on top of each other, are SELECTs on
> views that do not specify a SORT order guaranteed to preserve the cumulative
> sort order of the lower-level views ?
>
> Is the answer true for any arbitrarily large set of layered views?
>
> Is the answer the same if the layers of relations are a mix of views and
> tables ?

If a view definition includes an ORDER BY clause, the output of that
view will be sorted accordingly.  But if you do something with that
output, like join it to another table, then the join might disturb the
sort order.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to