Re: patch - support for multi-dimensional arrays and NULL values

From: Marek Lewczuk <newsy(at)lewczuk(dot)com>
To: pgsql-jdbc(at)postgresql(dot)org, books(at)ejurka(dot)com
Subject: Re: patch - support for multi-dimensional arrays and NULL values
Date: 2007-07-09 09:00:24
Message-ID: 4691F928.9010000@lewczuk.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

Marek Lewczuk pisze:
> Hello Kris and hello group,
> in the attachment you can find AbstractJdbc2Array class with two fixed
> features: null value as element of an array and... multi-dimensional
> arrays support. There are two things related with this two changes:
> - all arrays are objects arrays (which means that e.g. boolean[] is
> represented as Boolean[])
> - when multi-dimensional array is processed then Object[] is returned by
> getArray() - it's because we can't declare in Java an array of unknown
> dimension (so if PostgreSQL returns char[][] then jdbc will return
> Object[], that contains String[] elements)
>
> Sorry that I didn't send patch file, but I didn't have time to install
> cvs client (I'm using svn in everyday work).
>
> In case of questions or any other discussion write me an email.
>
> Best regards,
> Marek Lewczuk
Small correction to my previous post - I forgot to include null support
when bulding final arrays. In the attachment corrected file.

Attachment Content-Type Size
AbstractJdbc2Array.java text/plain 18.5 KB

In response to

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Altaf Malik 2007-07-09 11:58:27 Unable to prepare a statement when the object names contain more than one $ symbol
Previous Message Dave Cramer 2007-07-08 21:11:15 Re: Connection is closed. Operation is not permitted. ------HELP....