null: was is the default returned value? - Mailing list pgsql-jdbc

From Jean-Christian Imbeault
Subject null: was is the default returned value?
Date
Msg-id 3DB3954E.5070304@mega-bucks.co.jp
Whole thread Raw
Responses Re: null: was is the default returned value?
List pgsql-jdbc
What value does the jdbc driver return from the various getXXX()
functions when the DB return value is null?

I've been having some trouble using getObject() and getStr() on
ResultSets that contain null values for some fields.

If I do Object o = r.getObject("col") and the returned value is null I
get a nullPointeException. But for String s = r.getStr("col") I get a
value that prints out as "null" ... so if getStr() works I don't
understand why getObject() doesn't ...

Thanks,

Jc


pgsql-jdbc by date:

Previous
From: Aaron Mulder
Date:
Subject: Re: new String(byte[]) performance
Next
From: Antonie C Malan
Date:
Subject: Trouble connecting