Re: I found a bug in the jdbc driver - Mailing list pgsql-jdbc

From Kris Jurka
Subject Re: I found a bug in the jdbc driver
Date
Msg-id Pine.LNX.4.33.0305260328580.26009-100000@leary.csoft.net
Whole thread Raw
In response to I found a bug in the jdbc driver  (innuendo-nh@libero.it <innuendo-nh@libero.it>)
List pgsql-jdbc

On Thu, 22 May 2003 =?iso-8859-1?Q?innuendo-nh@libero.it?= wrote:

> I have just found a bug in the latest jdbc driver.
>
> The error is in the class org.postgresql.jdbc2.AbstractJdbc2ResultSet
>
> the method parseQuery() has a bug:

There are a number of problems with this method.  It is a very simple
function trying to do a very complicated task.  I noted this in
the following message in December...

What could really use some work is the parseQuery method in
org.postgresql.jdbc2.AbstractJdbc2ResultSet.  When determining if a
ResultSet can be updated it does not check that all colums of the result
set aren't derived columns.  The check to make sure it is a single table
is not particularly good.  It fails on things like:

SELECT CURRENT_TIMESTAMP;
SELECT a AS from FROM t;
SELECT a FROM t1 LEFT JOIN t2 ON (t1.id=t2.id);
SELECT a FROM t1 UNION SELECT a FROM t2;

I'm not sure how much this can be improved without building a full blown
parser into the driver.


pgsql-jdbc by date:

Previous
From: Holger Klawitter
Date:
Subject: Re: some troubles with accent by using java with postgres
Next
From: Csaba Nagy
Date:
Subject: Re: I found a bug in the jdbc driver