From: | Peter Mount <peter(at)retep(dot)org(dot)uk> |
---|---|
To: | <cmarkiew(at)commnav(dot)com>, <pgsql-jdbc(at)postgresql(dot)org> |
Cc: | <chris(dot)markiewicz(at)commnav(dot)com> |
Subject: | RE: null to zero? |
Date: | 2001-04-10 15:49:56 |
Message-ID: | 5.0.2.1.0.20010410164836.00a34210@mail.retep.org.uk |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
At 10:59 06/04/01 -0400, chris markiewicz wrote:
>hello.
>
>it seems that a null value in an integer (int4) column gets converted to
>zero at some point...is this accurate? i look in the db and see null
>(queried using IS NULL to make sure), but i call an rs.getObject(colName)
>and get a java.lang.Integer with a value of zero...is this in jdbc or java?
>an Integer can BE null, but it cannot have a value of null...
I'll check the specs. IIRC getObject on a null'ed field should return null,
but I have a feeling this question came up recently (well a few months ago).
>didn't see anything in the archives...
Whew, someone who has looked at them ;-)
Peter
>thanks
>chris
>
>
>---------------------------(end of broadcast)---------------------------
>TIP 6: Have you searched our list archives?
>
>http://www.postgresql.org/search.mpl
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Mount | 2001-04-10 15:55:23 | Re: JDBC and Perl compiling problems w/ postgresql-7.1rc4 |
Previous Message | Peter Mount | 2001-04-10 15:48:20 | Re: Error codes in JDBC drivers |