Re: DatabaseMetaData.getTables()

From: "Dave Cramer" <Dave(at)micro-automation(dot)net>
To: <pgsql-jdbc(at)postgresql(dot)org>
Subject: Re: DatabaseMetaData.getTables()
Date: 2001-10-28 11:57:27
Message-ID: 00bc01c15fa7$b74bf470$8201a8c0@inspiron
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Yes, I had a look at this, and it is confirmed to be broken in the CVS
tip. You can try the driver from jdbc.postgresql.org. It may be more
stable. This did work recently ;(

Dave

-----Original Message-----
From: pgsql-jdbc-owner(at)postgresql(dot)org
[mailto:pgsql-jdbc-owner(at)postgresql(dot)org] On Behalf Of Jason Davies
Sent: October 27, 2001 8:26 PM
To: pgsql-jdbc(at)postgresql(dot)org
Subject: [JDBC] DatabaseMetaData.getTables()

Hi,

There seems to be a problem with DatabaseMetaData.getTables() when I do
the following:

ResultSet R=conn.getMetaData().getTables(null, null, "%", null);

It throws a NullPointerException:

java.lang.NullPointerException
at
org.postgresql.jdbc2.DatabaseMetaData.getTables(DatabaseMetaData.java:17
32)
at Test.main(Test.java:66)

Looking at the source, ResultSet.getBytes() is called and it returns
null, causing this exception to be thrown. However I can use
ResultSet.getString() without a problem. I'm using 7.1.3 at the moment.
Does ResultSet.getBytes() need to be fixed or should getTables() be
modified?

I'd be grateful for any insights. Or you can just tell me to use the
latest cvs version of PostgreSQL :) What is the consensus on supporting
older versions, will you phase out old code when 7.2 comes out?

--
Jason Davies

jason(at)netspade(dot)com

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Dave Cramer 2001-10-28 12:14:42 Re: DatabaseMetaData.getTables()
Previous Message Rene Pijlman 2001-10-28 09:07:06 Re: DatabaseMetaData.getTables()