Re: Proposal to allow setting cursor options on Portals

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Dave Cramer <davecramer(at)gmail(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Jelte Fennema-Nio <postgres(at)jeltef(dot)nl>, Jacob Champion <jacob(dot)champion(at)enterprisedb(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi>
Subject: Re: Proposal to allow setting cursor options on Portals
Date: 2026-01-14 19:24:09
Message-ID: CA+TgmoavFJW984Y8cUv-U9K+JqxYgqEj-i1A1dORwvyki5642A@mail.gmail.com
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Jan 9, 2026 at 1:20 PM Dave Cramer <davecramer(at)gmail(dot)com> wrote:
> For the particular case of adding the ability to create holdable cursors at the protocol level which is what my patch is concerned with I don't think it's even necessary to bump the protocol or create a protocol extension.
> The change in the message is backward compatible and clients only need to know that after version 18 they can use the message to create a holdable cursor. I would argue that this patch is just rectifying an oversight in the original protocol.

I'm not sure what I think about the patch itself, but I find myself
somewhat in agreement with this logic. If the server is supposed to
start sending something different to the client, or the client must
send something different to the server, that's clearly got to be
negotiated. But I wonder whether we should just consider slipping
things like this into the protocol without bumping the version at all.
That makes me a bit nervous because it kind of makes a mockery of the
idea of a version number, but it's also not entirely without
precedent. For example, COPY BOTH mode didn't use to exist, and now it
does, and the protocol version number didn't change in the process.

--
Robert Haas
EDB: http://www.enterprisedb.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message David Christensen 2026-01-14 19:26:03 [PATCH] Fix incorrect parser comment
Previous Message Kirill Reshke 2026-01-14 19:14:33 Re: code contributions for 2025, WIP version