pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Kris Jurka <books@ejurka.com>
To: Igor Urisman <igor.urisman@gmail.com>
Cc: pgsql-jdbc@postgresql.org
Subject: Re: Improper type conversion from smallint to short
Date: Thu, 14 Mar 2013 19:27:02 -0500 (EST)
Message-ID: <alpine.BSO.2.00.1303141926050.13697@leary.csoft.net> (raw)
In-Reply-To: <CAJ9OwnUyCP022aagiCyO1kXGfWZwtqKPv-9YHWmr+T7MtqnhRA@mail.gmail.com>
References: <CAJ9OwnUyCP022aagiCyO1kXGfWZwtqKPv-9YHWmr+T7MtqnhRA@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-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
-- 
Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-jdbc



view thread (6+ messages)  latest in thread

Message-ID: <alpine.BSO.2.00.1303141926050.13697@leary.csoft.net>
Permalink:  ../alpine.BSO.2.00.1303141926050.13697@leary.csoft.net/
Also on:    postgresql.org/message-id/alpine.BSO.2.00.1303141926050.13697@leary.csoft.net

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-jdbc@postgresql.org
  Cc: books@ejurka.com, igor.urisman@gmail.com
  Subject: Re: Improper type conversion from smallint to short
  In-Reply-To: <alpine.BSO.2.00.1303141926050.13697@leary.csoft.net>
  References: <CAJ9OwnUyCP022aagiCyO1kXGfWZwtqKPv-9YHWmr+T7MtqnhRA@mail.gmail.com> <alpine.BSO.2.00.1303141926050.13697@leary.csoft.net>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox