Re: Performance Optimization for Dummies 2 - the SQL

Поиск
Список
Период
Сортировка
От Shaun Thomas
Тема Re: Performance Optimization for Dummies 2 - the SQL
Дата
Msg-id 200610161728.43193.sthomas@leapfrogonline.com
обсуждение исходный текст
Ответ на Re: Performance Optimization for Dummies 2 - the SQL  ("Carlo Stonebanks" <stonec.register@sympatico.ca>)
Список pgsql-performance
On Monday 16 October 2006 16:37, Carlo Stonebanks wrote:

> The facility_address_id is null statement is necessary, as this is a
> sub-query from a union clause and I want to optimise the query with
> the original logic intact. The value is not hard coded to true but
> rather to null.

Heh, you neglect to mention that this query is discovering faculty who
do *not* have an address entry, which makes the "is null" a major
necessity.  With that, how did a "not exists (blabla faculty_address
blabla)" subquery to get the same effect treat you?  How about an "IN
(blabla LIMIT 1)" ?

--

Shaun Thomas
Database Administrator

Leapfrog Online
807 Greenwood Street
Evanston, IL 60201
Tel. 847-440-8253
Fax. 847-570-5750
www.leapfrogonline.com

В списке pgsql-performance по дате отправления:

Предыдущее
От: "Carlo Stonebanks"
Дата:
Сообщение: Re: Performance Optimization for Dummies 2 - the SQL
Следующее
От: "Carlo Stonebanks"
Дата:
Сообщение: Re: Performance Optimization for Dummies 2 - the SQL