Re: tuning SQL

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: tuning SQL
Дата
Msg-id 14789.1012323474@sss.pgh.pa.us
обсуждение исходный текст
Ответ на tuning SQL  ("Zhang, Anna" <azhang@verisign.com>)
Список pgsql-admin
"Zhang, Anna" <azhang@verisign.com> writes:
> select count(*) from contact a, contact_discard b where a.contacthandle <>
> b.contacthandle;

Did you really mean "<>" here?  If so, the plan you showed us is not for
this query.  The above query is going to take approximately forever to
execute :-(

If you meant "=", then the hash join that the system is using seems like
a perfectly fine plan to me.

            regards, tom lane

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

Предыдущее
От: "Ross J. Reedstrom"
Дата:
Сообщение: Re: tuning SQL
Следующее
От: "Zhang, Anna"
Дата:
Сообщение: Re: tuning SQL