getObject and SMALLINT (JDBC)

Поиск
Список
Период
Сортировка
От Wim Ceulemans
Тема getObject and SMALLINT (JDBC)
Дата
Msg-id 38292CC8.F96A6BA8@nice.be
обсуждение исходный текст
Список pgsql-interfaces
Hi

I noticed that all jdbc drivers return the Integer java type for a
SMALLINT database type. Is this intended or is this a bug? The
recommendation in the JDBC book (Hamiltan, Catell, Fisher) says that
SMALLINT should be mappped to the Java short type.

If I want to changes this, is all I have to do is change the line in
/src/interfaces/jdbc/postgresql/jdbc1/ResultSet.java from

case Types.SMALLINTreturn new Integer(getInt(columnIndex)
to

case Types.SMALLINTreturn new Short(getShort(columnIndex)
?

Regards

Wim Ceulemans
Nice bvba www.nice.be
Eglegemweg 3, 2811 Hombeek Belgium
Tel 0032-15-412953 Fax 0032-15-412954


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

Предыдущее
От: "Ansley, Michael"
Дата:
Сообщение: RE: [INTERFACES] Re: [HACKERS] CORBA STATUS
Следующее
От: Peter Mount
Дата:
Сообщение: RE: [INTERFACES] getObject and SMALLINT (JDBC)