Re: patch to create system view that lists cursors - Mailing list pgsql-patches

From Tom Lane
Subject Re: patch to create system view that lists cursors
Date
Msg-id 19897.1137113518@sss.pgh.pa.us
Whole thread Raw
In response to Re: patch to create system view that lists cursors  (Neil Conway <neilc@samurai.com>)
Responses Re: patch to create system view that lists cursors  (Neil Conway <neilc@samurai.com>)
List pgsql-patches
Neil Conway <neilc@samurai.com> writes:
> Why list Portals that cannot be directly manipulated by the user?

Define "directly manipulated".  AFAIR there isn't any particular
distinction between portals that got made by DECLARE CURSOR and those
that got made by Bind; you can use either EXECUTE or Fetch for either.
Also, a portal that has gone into ERROR state should still be listed,
IMHO, because the behavior the user will expect is that it's there until
he CLOSEs it.

> It would also mean that this would produce unexpected results:
> "PREPARE foo AS SELECT * FROM pg_cursors; EXECUTE foo".

Unexpected in what sense?

            regards, tom lane

pgsql-patches by date:

Previous
From: Neil Conway
Date:
Subject: Re: patch to create system view that lists cursors
Next
From: Christopher Kings-Lynne
Date:
Subject: Re: patch to create system view that lists cursors