Re: BUG #19107: The hold cursor is unexpectedly released during rollback

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: zengman@halodbtech.com
Cc: pgsql-bugs@lists.postgresql.org
Date: 2025-11-10T16:04:00Z
Lists: pgsql-bugs
PG Bug reporting form <noreply@postgresql.org> writes:
> While I was writing test cases for the hold cursor, I unexpectedly
> discovered that commit and rollback handle it inconsistently—rollback
> unexpectedly releases the hold cursor. Should this be regarded as a bug?

No, that's intentional.  The rollback might be cleaning up a failure
in the held cursor.

			regards, tom lane