pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Roberta Campo <rcampo@mm.eutelsat.org>
To: pgsql-jdbc@postgresql.org
Subject: PreparedStatement.setXXX
Date: Mon, 18 Jul 2005 13:55:23 +0200
Message-ID: <dbg5ba$2g9c$3@news.hub.org> (raw)

We're moving from Postgresql7.4 to v.8.0.3,
with some problems rising from the strictness of the new driver
postgresql-8.0-311.jdbc3.jar.

We used to call a function f(integer[]) using
PreparedStatement.setString('{...}')
but now the types are not compatible.


How should we fix that ?

A. Using the setArray method :
This requires the implementation of the interface java.sql.Array :
- which methods are required in this case ?
- is there any available implementation of this class ? :)

B. Using the setObject(colnumber, String, type ) method :
This should require less implementation than the Array, shouldn't it ?
- how to specify the type int[] ?

C. Using different drivers / protocol versions / ...

 Thanks,
Roberta





view thread (4+ messages)  latest in thread

Message-ID: <dbg5ba$2g9c$3@news.hub.org>
Permalink:  ../dbg5ba$2g9c$3@news.hub.org/
Also on:    postgresql.org/message-id/dbg5ba$2g9c$3@news.hub.org

 · 

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: rcampo@mm.eutelsat.org
  Subject: Re: PreparedStatement.setXXX
  In-Reply-To: <dbg5ba$2g9c$3@news.hub.org>
  References: <dbg5ba$2g9c$3@news.hub.org>

* 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