Re: Using PQexecQuery in pipeline mode produces unexpected Close messages - Mailing list pgsql-bugs

From Alvaro Herrera
Subject Re: Using PQexecQuery in pipeline mode produces unexpected Close messages
Date
Msg-id 202206081508.pwq4ne3df2si@alvherre.pgsql
Whole thread Raw
In response to Using PQexecQuery in pipeline mode produces unexpected Close messages  (Daniele Varrazzo <daniele.varrazzo@gmail.com>)
List pgsql-bugs
On 2022-Jun-08, Daniele Varrazzo wrote:

> Is this a problem with PQexecQuery which should not send the Close, or
> with receiving in IDLE mode which should expect a CloseComplete?

Interesting.

What that Close message is doing is closing the unnamed portal, which
is otherwise closed implicitly when the next one is opened.  That's how
single-query mode works: if you run a single portal, it'll be kept open.

I believe that the right fix is to not send that Close message in
PQsendQuery.

-- 
Álvaro Herrera               48°01'N 7°57'E  —  https://www.EnterpriseDB.com/
"Para tener más hay que desear menos"



pgsql-bugs by date:

Previous
From: Christoph Berg
Date:
Subject: Re: Fallout from 'Make type "name" collation-aware' and tg_table_name
Next
From: PG Bug reporting form
Date:
Subject: BUG #17513: recompressing already-compressed data via VACUUM FULL or CLUSTER does not work