Skip site navigation (1) Skip section navigation (2)

getObject and SMALLINT (JDBC)

From: Wim Ceulemans <wim(dot)ceulemans(at)nice(dot)be>
To: pgsql-interfaces(at)postgresql(dot)org
Subject: getObject and SMALLINT (JDBC)
Date: 1999-11-10 08:28:56
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-interfaces

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/ from

case Types.SMALLINT
	return new Integer(getInt(columnIndex)

case Types.SMALLINT
	return new Short(getShort(columnIndex)


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

pgsql-interfaces by date

Next:From: Peter MountDate: 1999-11-10 09:14:14
Subject: RE: [INTERFACES] getObject and SMALLINT (JDBC)
Previous:From: Constantin TeodorescuDate: 1999-11-10 07:16:00
Subject: Re: pgaccess on Windows NT

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group