>
> Does the portal store all the rows at the backend and feed them one by one
> to the client, or does it go out to disk to get new rows?
Check out PerformPortalFetch(). Looks like it creates a memory area for
each portal, and allows you to move around in it. This is probably why
a transaction is needed, because the memory is probably in a
transaction-specific pool that gets automatically freed at the end of
transactions.
But then if you look at the ExecutorRun() call, it appears to re-execute
the entire query for each fetch, which is a terrible waste. So it may
be only saving the executor 'plan' in memory, and reexecuting it for
each fetch, rather than saving off the result of the query.
Perhaps someone can comment on this. Vadim is on vacation until July
24th.
- --
Bruce Momjian
maillist@candle.pha.pa.us
------------------------------