From: | "Alon Goldshuv" <agoldshuv(at)greenplum(dot)com> |
---|---|
To: | pgsql-hackers(at)postgreSQL(dot)org |
Subject: | Unnecessary rescan for non scrollable holdable cursors |
Date: | 2006-08-28 18:50:35 |
Message-ID: | C118B33B.139C0%agoldshuv@greenplum.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Hi,
When persisting a holdable cursor at COMMIT time we currently choose to
rewind the executor and re-scan the whole result set into the tuplestore in
order to be able to scroll backwards later on. And then, we reposition the
cursor to the position we been in. However, unless I am missing something,
this seems to be done always, even if the cursor is not scrollable. I
suppose adding a simple conditional or two in PersistHoldablePortal() in
portalcmds.c could save the rescan and filling up the tuplestore with tuples
that will never be looked at, in the case that we never want to scroll back.
Anyway, definitely not critical, but should save some time and space in
those specific situations.
Regards,
Alon.
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2006-08-28 18:51:17 | Re: autovacuum causing numerous regression-test failures |
Previous Message | Tom Lane | 2006-08-28 18:33:22 | autovacuum causing numerous regression-test failures |