JDBC driver build 215 slow when index contains column of type BIGINT

Поиск
Список
Период
Сортировка
От Roland Walter
Тема JDBC driver build 215 slow when index contains column of type BIGINT
Дата
Msg-id 422EC149.5040306@mosaic-ag.com
обсуждение исходный текст
Ответы Re: JDBC driver build 215 slow when index contains column
Re: JDBC driver build 215 slow when index contains column
Список pgsql-jdbc
Hello!

I use PostgreSQL 7.4.6 and the JDBC-driver build 215. I have
a table of the form

create table business_case (
  bc_id BIGINT PRIMARY KEY,
  ...
);

To update a row, I use a PreparedStatement of the form

update business_case set ... where bc_id=?

I use setLong() to set the value of bc_id, but the update
is slow, as the index on bigint does not get used.

Changing the JDBC-driver to build 310 increases the speed dramatically:
160 updates with build 215 consumed more than 10 minutes, with build 310
just about 3 seconds.

Have I to do a typecast to ::bigint with build 215 in the PreparedStatement
to get the same performance as with build 310? That would be bad, as I
had to
form the PreparedStatement incompatible to other databases.

Regards,
Roland.

--
Roland Walter
MOSAIC SOFTWARE AG
Telefon: 02225/882-411 Fax: 02225/882-201
http://www.mosaic-ag.com


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

Предыдущее
От: Antony Paul
Дата:
Сообщение: Re: FW: PreparedStatement#setString on non-string parameters
Следующее
От: Roland Walter
Дата:
Сообщение: Re: JDBC driver build 215 slow when index contains column