| From: | RW Shore <rws228(at)gmail(dot)com> |
|---|---|
| To: | Oliver Jowett <oliver(at)opencloud(dot)com> |
| Cc: | pgsql-jdbc(at)postgresql(dot)org |
| Subject: | Re: Array type error |
| Date: | 2011-02-14 12:52:26 |
| Message-ID: | AANLkTikr8cO6hujSSycMN1Mi7a9j3hDjTYQMtor+vfjH@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-jdbc |
Thanks for the response. My issue is that the input and output formats
aren't interchangable. The application in question is part of a replication
system that converts changes into XML, processes the changes, and ultimately
applies them to a target database. If the array instance says that it
contains BIT data, I try to extract the array contents as a binary array;
this won't work if the actual array contents are BOOLEAN. Also, as far as I
can tell, the only way to insert an array value is to stringify it; the
string representation for a bit array is quite different from that of a
boolean array.
I understand the interchangability of bit(1) and boolean at a certain level,
but IMO this is still an inconsistency at best if not an outright bug.
On Mon, Feb 14, 2011 at 6:29 AM, Oliver Jowett <oliver(at)opencloud(dot)com> wrote:
> RW Shore wrote:
>
>> However, the getBaseType( ) method on this object returns
>> java.sql.Types.BIT ( -7 ) rather than the correct value
>> java.sql.Types.BOOLEAN (16).
>>
>
> These types are effectively interchangeable in JDBC.
> See the list archives for past discussion.
>
> Oliver
>
>
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Oliver Jowett | 2011-02-14 13:13:00 | Re: Array type error |
| Previous Message | Lukas Eder | 2011-02-14 12:20:56 | Re: UDT arrays |