Re: Adaptive query execution

From: Tim Kane <tim(dot)kane(at)gmail(dot)com>
To: Claudio Freire <klaussfreire(at)gmail(dot)com>
Cc: "pgsql-performance(at)postgresql(dot)org" <pgsql-performance(at)postgresql(dot)org>
Subject: Re: Adaptive query execution
Date: 2014-05-13 20:33:58
Message-ID: CF983E13.7EFDD%tim.kane@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

>
>
> From: Claudio Freire <klaussfreire(at)gmail(dot)com>
>> I thought I would see what happens when I do this:
>>
>> SELECT * FROM ONLY table_a UNION SELECT * FROM table_b;
>>
>>
>>
> What's the point, in the context of this example?
>
> The sort-unique still has to be performed even if you didn't have data
> in one side, since the other could still have duplicates.

Damn it. Okay, bad example. I should sleep.

A better example would be (from my other post just now -
http://www.postgresql.org/message-id/CF9838D8.7EF3D%tim.kane@gmail.com )
where an empty parent-table is append’ed into a result set involving one
(and only one) of its child relations. Whereas a more optimum solution
would involve only the child relation without the need to append the empty
parent relation.

I’m sure there are other scenarios where adaptive query execution would be
of greater benefit.

Tim

>

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Tim Kane 2014-05-13 20:57:10 Re: Constraint exclusion won't exclude parent table
Previous Message Tom Lane 2014-05-13 20:24:39 Re: Constraint exclusion won't exclude parent table