From: | Tatsuo Ishii <ishii(at)sraoss(dot)co(dot)jp> |
---|---|
To: | andres(at)anarazel(dot)de |
Cc: | davidr(at)openscg(dot)com, ishii(at)sraoss(dot)co(dot)jp, tgl(at)sss(dot)pgh(dot)pa(dot)us, pgfizm(at)gmail(dot)com, pgsql-general(at)postgresql(dot)org |
Subject: | Re: Protocol 2 and query parameters support |
Date: | 2017-04-24 23:11:46 |
Message-ID: | 20170425.081146.1187742164733573724.t-ishii@sraoss.co.jp |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
> On 2017-04-24 16:07:01 -0400, Rader, David wrote:
>> As Tom mentioned, it sounds like the issue is that Presto expects to only
>> use simple query, not extended query (no server-side prepared statements).
>> The JDBC driver supports setting the prepare threshold to 0 to disable
>> using server-side prepares.
>>
>> https://jdbc.postgresql.org/documentation/publicapi/org/postgresql/PGStatement.html#setPrepareThreshold-int-
>>
>> "If threshold is zero, server-side prepare will not be used."
>
> Note that you can use the extended protocol without server side
> prepares...
Quite correct. Just setting the prepare threshold to 0 does not
prevent PostgreSQL from using extended queries. So the only way not
using extended queires with JDBC is setting the protocol version to 2.
I wonder why PostgreSQL JDBC does not provide similar API to ODBC...
Best regards,
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese:http://www.sraoss.co.jp
From | Date | Subject | |
---|---|---|---|
Next Message | Andres Freund | 2017-04-25 04:17:43 | Questionaire: Common WAL write rates on busy servers. |
Previous Message | Andres Freund | 2017-04-24 20:11:26 | Re: Protocol 2 and query parameters support |