Re: Improper type conversion from smallint to short

From: Kris Jurka <books(at)ejurka(dot)com>
To: Igor Urisman <igor(dot)urisman(at)gmail(dot)com>
Cc: pgsql-jdbc(at)postgresql(dot)org
Subject: Re: Improper type conversion from smallint to short
Date: 2013-03-15 00:27:02
Message-ID: alpine.BSO.2.00.1303141926050.13697@leary.csoft.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

On Thu, 14 Mar 2013, Igor Urisman wrote:

> Hello,It appears that ResultSet.getObject(String name) returns Integer for
> database type Types.SMALLINT (5)  I expected Short.
>

Returning Integer is correct according to the JDBC spec. See table 8.6.3
here:

http://www.cis.upenn.edu/~bcpierce/courses/629/jdkdocs/guide/jdbc/getstart/mapping.doc.html

Kris Jurka

In response to

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Igor Urisman 2013-03-15 01:17:14 Re: Improper type conversion from smallint to short
Previous Message Igor Urisman 2013-03-14 22:27:18 Improper type conversion from smallint to short