Re: RE : Postgres 8.0 + JDBC - Mailing list pgsql-jdbc

From Kris Jurka
Subject Re: RE : Postgres 8.0 + JDBC
Date
Msg-id Pine.BSO.4.56.0410141609250.18563@leary.csoft.net
Whole thread Raw
In response to Re: RE : Postgres 8.0 + JDBC  (Kris Jurka <books@ejurka.com>)
List pgsql-jdbc

On Wed, 6 Oct 2004, Kris Jurka wrote:

> On Wed, 6 Oct 2004, Johann Robette wrote:
>
> > But as I'm a newbie in this field, could you give me an example of how
> > to do that.
>
> It's not something you can do in your code.  It will require changes to
> the driver itself.  Oliver or I will do this at some point, but I couldn't
> say when.  If you're desperate to get a fix immediately I've attached a
> patch implementing the inferior solution I suggested that made a simple
> test work for me.
>

Just wanted to follow up with you here in case you weren't carefully
following the mailing list.  Oliver has provided a patch to make this
happen and it is now in the cvs repository.

It does require some changes to the PostgresArray class you sent.  Notably
the datatype name needs to match up exactly with the pg data type (aliases
aren't allowed).  So for example the create(long[] array) method currently
creates does this at the end:

return new PostgresArray(sb.toString(), Types.BIT, "bigint");

this now needs to use "int8" as the type name.  The Types.BIT is also
bogus, but that currently isn't a problem.

Kris Jurka

pgsql-jdbc by date:

Previous
From: Paul Thomas
Date:
Subject: Re: PostgreSQL Database interfaced by Java Applet
Next
From: Ian Pilcher
Date:
Subject: Mining SQLException for info