Re: Using IN with subselect

Поиск
Список
Период
Сортировка
От Martijn van Oosterhout
Тема Re: Using IN with subselect
Дата
Msg-id 20041125172542.GC28393@svana.org
обсуждение исходный текст
Ответ на Re: Using IN with subselect  (Dave Smith <dave.smith@candata.com>)
Список pgsql-general
On Thu, Nov 25, 2004 at 12:19:23PM -0500, Dave Smith wrote:
> Well here is explain. I would guess that it is executed each time ..
> function any different?

Hmm, if it's only executed once I would expect it to be an InitPlan.
Are you sure it's not correlated?

If you want to make sure, put the subquery in the FROM clause, that it
definitly will only be run once.

<snip>

Hope this helps,
--
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a
> tool for doing 5% of the work and then sitting around waiting for someone
> else to do the other 95% so you can sue them.

Вложения

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

Предыдущее
От: "Julian Scarfe"
Дата:
Сообщение: How can I change a cast from explicit only to implicit?
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Using IN with subselect