[pgpool-committers: 9479] pgpool: Fix PREPARE in multi-statement case.
Tatsuo Ishii
ishii at sraoss.co.jp
Thu Jul 13 11:34:22 JST 2023
Fix PREPARE in multi-statement case.
If multi-statement query includes PREPARE in the second or latter
position, and subsequent bind message uses the prepared statement, it
fails with "unable to bind" error because the prepared statement is not
saved in sent messages.
To fix this if such a case found after parsing the statement, create a
query context for the named statement and add it to the sent message
list.
Discussion: https://www.pgpool.net/pipermail/pgpool-general/2023-July/008931.html
For this new regression test 079..multi_prepare is added.
Branch
------
V4_4_STABLE
Details
-------
https://git.postgresql.org/gitweb?p=pgpool2.git;a=commitdiff;h=1f5b7c8b967ed37796713ed3c3eb5b6b2b9db7e4
Modified Files
--------------
src/protocol/pool_proto_modules.c | 59 ++++++++++++++++++++++
.../tests/079.multi_prepare/expected.txt | 23 +++++++++
.../tests/079.multi_prepare/pgproto.data | 16 ++++++
.../regression/tests/079.multi_prepare/test.sh | 39 ++++++++++++++
4 files changed, 137 insertions(+)
More information about the pgpool-committers
mailing list