IN clauses via setObject(Collection) [Was: Re: Prepared Statements]

From: Oliver Jowett <oliver(at)opencloud(dot)com>
To: Fernando Nasser <fnasser(at)redhat(dot)com>
Cc: Dmitry Tkach <dmitry(at)openratings(dot)com>, Kim Ho <kho(at)redhat(dot)com>, Barry Lind <blind(at)xythos(dot)com>, pgsql-jdbc-list <pgsql-jdbc(at)postgresql(dot)org>, Dave Cramer <Dave(at)micro-automation(dot)net>
Subject: IN clauses via setObject(Collection) [Was: Re: Prepared Statements]
Date: 2003-07-21 15:47:49
Message-ID: 20030721154748.GN2506@opencloud.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

On Mon, Jul 21, 2003 at 11:26:11AM -0400, Fernando Nasser wrote:

> I think Dima is arguing that Collection could be treated as an special case
> where it indicates a list of something instead of a single something.
>
> So, we would iterate through this Collection using its iterator and, for
> each Object obtained, act like a setObject has been used with that Object
> and the JAVA TYPE as an argument.
>
> The Types.OTHER is used for database specific SQL types or for Dynamic Data
> Access support. As the Collection class is not a data type there is no
> chance of confusion.

Ya, I understand. My main objection is that setObject(n, object,
Types.INTEGER), in all other cases, means "interpret object as an integer,
or fail if it can't be cast in that way".

-O

In response to

Responses

Browse pgsql-jdbc by date

  From Date Subject
Next Message Fernando Nasser 2003-07-21 15:50:38 RFC: Removal of support for JDBC1 drivers.
Previous Message Fernando Nasser 2003-07-21 15:44:41 Re: patch: clean up ant test infrastructure