pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Craig Ringer <craig@2ndquadrant.com>
To: robrez <resendez.java@gmail.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: Inconsistent:  Getting array from result set
Date: Mon, 28 Oct 2013 11:29:10 +0800
Message-ID: <526DDA06.6010300@2ndquadrant.com> (raw)
In-Reply-To: <1382657236721-5775841.post@n5.nabble.com>
References: <1382657236721-5775841.post@n5.nabble.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-jdbc>

On 10/25/2013 07:27 AM, robrez wrote:
> I am encountering inconsistent behavior when getting an array from a result
> set that was produced via a prepared statement.
> 
> It seems that the first 5 times the result set is generated from a given
> statement, everything is good.
> Attempts 6-n do something strange.

By default, PgJDBC switches from client-side to server-side prepared
statements at five executions. So I'd say you're seeing an issue related
to that.

Try playing with the prepared statement threshold, see if the problem
behaviour changes along with the threshold. See the documentation for
details on that.


-- 
 Craig Ringer                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services


-- 
Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-jdbc



view thread (7+ messages)  latest in thread

Message-ID: <526DDA06.6010300@2ndquadrant.com>
Permalink:  ../526DDA06.6010300@2ndquadrant.com/
Also on:    postgresql.org/message-id/526DDA06.6010300@2ndquadrant.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: craig@2ndquadrant.com, resendez.java@gmail.com
  Subject: Re: Inconsistent:  Getting array from result set
  In-Reply-To: <526DDA06.6010300@2ndquadrant.com>
  References: <1382657236721-5775841.post@n5.nabble.com> <526DDA06.6010300@2ndquadrant.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox