Re: does postgresql execute unions in parallel?

Поиск
Список
Период
Сортировка
От Christopher Browne
Тема Re: does postgresql execute unions in parallel?
Дата
Msg-id 604qyz2t20.fsf@dev6.int.libertyrms.info
обсуждение исходный текст
Ответ на Re: does postgresql execute unions in parallel?  (Gaetano Mendola <mendola@bigfoot.com>)
Список pgsql-sql
mendola@bigfoot.com (Gaetano Mendola) writes:
> teknokrat wrote:
>> If I have several selects joined with unions does postgresql
>> execute the concurrently or not?
>
> nope.

I was talking with Jan about that very idea yesterday; this would seem
to be the place where PostgreSQL might take some (possibly even nearly
magical :-)) benefit from threading.

The usual way that people expect to use threading is for each
connection to have a thread.

If, instead, every _join_ had a thread, that would allow producers of
data to look for their data quasi-independently, passing result sets
upwards towards the return set to whatever thread was waiting to
consume the data.  

This would allow one complex query to take over a whole horde of
processors :-).

The "magic" part would be if the system decided, "The SEQ SCAN on the
table I'm looking at is a big one; let's split it into 4 chunks, doing
a virtual UNION ALL, and thereby filter bits of it in parallel on 4
CPUs."  That would provide many of the benefits Informix claimed from
"fragmentation" without having to fragment the table :-).
-- 
If this was helpful, <http://svcs.affero.net/rm.php?r=cbbrowne> rate me
http://www3.sympatico.ca/cbbrowne/lsf.html
Rules of the  Evil Overlord #187. "I will not  hold lavish banquets in
the middle of  a famine. The good PR among the  guests doesn't make up
for the bad PR among the masses."  <http://www.eviloverlord.com/>


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

Предыдущее
От: Gaetano Mendola
Дата:
Сообщение: Re: does postgresql execute unions in parallel?
Следующее
От: Bruce Momjian
Дата:
Сообщение: Re: [HACKERS] plpgsql doesn't coerce boolean expressions to boolean