From: | PFC <lists(at)peufeu(dot)com> |
---|---|
To: | "Jim C(dot) Nasby" <jnasby(at)pervasive(dot)com> |
Cc: | pgsql-performance(at)postgresql(dot)org, pgsql-hackers(at)postgresql(dot)org |
Subject: | Re: [HACKERS] Big IN() clauses etc : feature proposal |
Date: | 2006-05-10 19:35:39 |
Message-ID: | op.s9coppqfcigqcu@apollo13 |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-performance |
> On Tue, May 09, 2006 at 06:29:31PM +0200, PFC wrote:
>> You mean the cursors'storage is in fact the same internal machinery
>> as a temporary table ?
>
> Use the source, Luke...
LOL, yeah, I should have, sorry.
> See tuplestore_begin_heap in backend/utils/sort/tuplestore.c and
> heap_create_with_catalog in backend/catalog/heap.c. You'll find that
> creating a tuplestore is far easier than creating a temp table.
I had used intuition (instead of the source) to come at the same
conclusion regarding the level of complexity of these two...
But I'll look at the source ;)
> Perhaps it would be worth creating a class of temporary tables that used
> a tuplestore, although that would greatly limit what could be done with
> that temp table.
Just selecting from it I guess, but that's all that's needed. Anymore
would duplicate the functionality of a temp table.
I find cursors awkward. The application can FETCH from them, but postgres
itself can't do it in SQL, unless using FOR.. IN in plpgsql...
It would be a powerful addition to be able to split queries, factor out
common parts between multiple queries, etc, using this system, it can even
be used to execute an inner part of a query, then plan the rest according
to the results and execute it... without the overhead of a temp table.
From | Date | Subject | |
---|---|---|---|
Next Message | Jim C. Nasby | 2006-05-10 20:14:23 | Re: sblock state on FreeBSD 6.1 |
Previous Message | PFC | 2006-05-10 19:27:21 | Re: [PERFORM] Big IN() clauses etc : feature proposal |
From | Date | Subject | |
---|---|---|---|
Next Message | Thomas Vatter | 2006-05-10 20:54:00 | Re: in memory views |
Previous Message | PFC | 2006-05-10 19:27:21 | Re: [PERFORM] Big IN() clauses etc : feature proposal |