JDBC2.0:PreparedStatement setArray

Поиск
Список
Период
Сортировка
От Luigi Ruggiero
Тема JDBC2.0:PreparedStatement setArray
Дата
Msg-id 3FAF6186.8080204@camara.co.za
обсуждение исходный текст
Ответы Re: JDBC2.0:PreparedStatement setArray  (Oliver Jowett <oliver@opencloud.com>)
Список pgsql-jdbc
Hi there,

I am trying to set an array type in the preparedStatement. We are using
a Postgres 7.3.2 database. The driver jar version used, pg73jdbc3.jar.
Does anyone have a clue on how to do this?

Here is a snippet of my code. The function address.getLines() returns an
array of String's. (see the commented line)


public void prepare(PreparedStatement pst) throws SQLException{
             pst.setInt(1, agency.getId());
           //pst.setObject(2, address.getLines(), java.sql.Types.ARRAY);
             pst.setString(3, address.getCountry());
             pst.setString(4, address.getRegion());
             pst.setString(5, address.getCity());
}

I know there is a patch somewhere for this, does anyone know where  can
find it?

Thanx
Luigi


В списке pgsql-jdbc по дате отправления:

Предыдущее
От: "Daniel Washusen"
Дата:
Сообщение: Re:
Следующее
От: Oliver Jowett
Дата:
Сообщение: Re: JDBC2.0:PreparedStatement setArray