Re: Bug in PL/pgSQL FOR cursor variant

From: Heikki Linnakangas <heikki(dot)linnakangas(at)enterprisedb(dot)com>
To: PostgreSQL Bugs <pgsql-bugs(at)postgresql(dot)org>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Subject: Re: Bug in PL/pgSQL FOR cursor variant
Date: 2010-07-05 09:14:53
Message-ID: 4C31A28D.1000906@enterprisedb.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

On 22/06/10 01:49, Heikki Linnakangas wrote:
> On 22/06/10 00:47, Heikki Linnakangas wrote:
>> Maybe it would be easier to somehow protect the portal then, and throw
>> an error if you try to close it. We could just mark the portal as
>> PORTAL_ACTIVE while we run the user statements, but that would also
>> forbid fetching or moving it. I'm thinking of a new "pinned" state,
>> which is like PORTAL_READY except that the portal can't be dropped like
>> in PORTAL_ACTIVE state.
>
> Like this.
>
> (I'll need to revert the broken commit before applying this)

Ok, here's my final patch for this that I'll commit shortly. I added a
new boolean for the "pinned" status in the end, rather than confuse it
with the portal status. It's simpler that way.

--
Heikki Linnakangas
EnterpriseDB http://www.enterprisedb.com

Attachment Content-Type Size
plpgsql-forc-fix-3.patch text/x-diff 19.3 KB

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Roman 2010-07-06 06:43:47 BUG #5542: Query optimization problem
Previous Message Craig Ringer 2010-07-04 09:37:04 Re: postgresql 8.3 on ubuntu 8.10 uppgrade,remove,or reinstall problem