Optimizing "exists"

Поиск
Список
Период
Сортировка
От Steve Crawford
Тема Optimizing "exists"
Дата
Msg-id 46EFFE52.8070008@pinpointresearch.com
обсуждение исходный текст
Ответы Re: Optimizing "exists"  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
Does the planner automatically add "limit 1" to "exists" sub-selects? In
other words, take an update like:
update foo
  set itexists = exists
  (select 1 from bar where bar.something = foo.something);

If the sub-select returns a large result set, will there be any benefit
to adding "limit 1" to the sub-select or does the query planner
automatically deduce that "limit 1" is the correct interpretation?

Cheers,
Steve


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

Предыдущее
От: Erik Jones
Дата:
Сообщение: Re: ON INSERT => execute AWK/SH/EXE?
Следующее
От: Steve Atkins
Дата:
Сообщение: Re: ON INSERT => execute AWK/SH/EXE?