Skip site navigation (1) Skip section navigation (2)

Bypassing useless ORDER BY in a VIEW

From: "Robins Tharakan" <tharakan(at)gmail(dot)com>
To: pgsql-performance(at)postgresql(dot)org
Subject: Bypassing useless ORDER BY in a VIEW
Date: 2008-02-28 14:31:19
Message-ID: 36af4bed0802280631ja29c636w2256fb329e14b95e@mail.gmail.com (view raw or flat)
Thread:
Lists: pgsql-performance
Hi,

While designing a complex database structure I wanted to ask a basic
question about views.

If I give an ORDER BY clause in a VIEW and then use it in another query
where the VIEW's ORDER BY is immaterial, would the planner be able to
discard this ORDER BY clause ?

Any pointers / feedbacks would be really helpful.

Regards,
*Robins Tharakan*

Responses

pgsql-performance by date

Next:From: Tom LaneDate: 2008-02-28 17:13:40
Subject: Re: Bypassing useless ORDER BY in a VIEW
Previous:From: Oleg BartunovDate: 2008-02-28 05:47:22
Subject: Re: t1.col like '%t2.col%'

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group