Re: On query rewrite

Поиск
Список
Период
Сортировка
От Sailesh Krishnamurthy
Тема Re: On query rewrite
Дата
Msg-id mjqlljdj7z3.fsf@cs.berkeley.edu
обсуждение исходный текст
Ответ на Re: On query rewrite  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: On query rewrite
Список pgsql-hackers
>>>>> "Tom" == Tom Lane <tgl@sss.pgh.pa.us> writes:
   >> Are these alternatives (pulling up vs not pulling up   >> subqueries) considered in different plans ?
   Tom> That particular choice is not --- we do it if we can, else   Tom> not.  Comparisons between different
alternativesare always   Tom> handled by computing cost estimates and choosing the lowest.
 

Thank you Tom (and Alvarro)

So I've understood pull_up_subqueries (called SELECT MERGE in
Starburst). 

What about things like:

1. DISTINCT PULLUP (Where you realize that you don't have to have an
explicit duplicate elimination operation because of what's done in the
subquery)

2. DISTINCT pushdown (when a dup elim. can be pushed down if the upper
querytree is performign DISTINCT set operations (UNION, INTERSECT etc)

3. Discarding DISTINCT in a subquery because the upper query uses the
subquery with existential quantification

In general, I'm trying to understand all the transformations that
pgsql will try to do .. I'm not trying to figure out plan enumeration
for basic boxes (simple query tree).

-- 
Pip-pip
Sailesh
http://www.cs.berkeley.edu/~sailesh




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

Предыдущее
От: Tatsuo Ishii
Дата:
Сообщение: Re: Nested xacts: looking for testers and review
Следующее
От: Gaetano Mendola
Дата:
Сообщение: Re: tablespaces and DB administration