Skip navigation links

MySQL Forums :: Connector/JDBC and Java :: Need java.sql.Array impl for PreparedStatement.setArray()


Advanced Search

Re: Need java.sql.Array impl for PreparedStatement.setArray()
Posted by: Mark Matthews ()
Date: July 01, 2005 11:11AM

Thomas Mayr wrote:
> Hello Mark Matthews,
>
> Oracle for example provides an implementation for
> the interface java.sql.Array! I'm looking for this
> feature as well. I read the Connector/J
> documentation but I didn't find a hint that the
> result set methods getArray(), updateArray() and
> the PreparedStatement methods setArray are not
> implemented! Where is this missing feature
> documented??
>
> Thanks Thomas.


Thomas,

1) Implementing Array is _optional_ according to the JDBC specification
2) You can determine whether a database supports the Array type through DataBaseMetadata.getTypeInfo().
3) Oracle's implementation is _not_ standards-compliant as far as I can tell (either SQL or JDBC). I interpret the specification as Array being a concrete type, so a driver and/or database that is SQL standard-compliant would see its use in an IN () statement matching a _column_ of the array type, not a list of values (which is how Oracle treats it as far as I know)

I'll make sure we document the fact that we don't implement it, however for _any_ vendor's driver your authoritative source would be DatabaseMetaData.getTypeInfo() _not_ the documentation (for example, with MySQL, support will be there when the server supports it, so whether or not it is supported in the future will depend on what version of the server the driver is connected to).

-Mark

Mark Matthews
Consulting Member Technical Staff - MySQL Enterprise Tools
Oracle
http://www.mysql.com/products/enterprise/monitor.html

Options: ReplyQuote


Subject Written By Posted
Need java.sql.Array impl for PreparedStatement.setArray() Dan Cooperstock 06/13/2005 11:57AM
Re: Need java.sql.Array impl for PreparedStatement.setArray() Mark Matthews 06/13/2005 01:38PM
Re: Need java.sql.Array impl for PreparedStatement.setArray() Dan Cooperstock 06/13/2005 01:42PM
Re: Need java.sql.Array impl for PreparedStatement.setArray() Mark Matthews 06/13/2005 01:46PM
Re: Need java.sql.Array impl for PreparedStatement.setArray() Thomas Mayr 07/01/2005 08:44AM
Re: Need java.sql.Array impl for PreparedStatement.setArray() Mark Matthews 07/01/2005 11:11AM
Re: Need java.sql.Array impl for PreparedStatement.setArray() Thomas Mayr 07/04/2005 06:47AM
Re: Need java.sql.Array impl for PreparedStatement.setArray() tauron 07/22/2005 07:39AM
Re: Need java.sql.Array impl for PreparedStatement.setArray() Mark Matthews 07/22/2005 08:38AM
Re: Need java.sql.Array impl for PreparedStatement.setArray() sam504u 01/11/2006 04:12PM
Re: Need java.sql.Array impl for PreparedStatement.setArray() Yogesh Gadge 01/22/2006 09:39AM
Re: Need java.sql.Array impl for PreparedStatement.setArray() konstantin kudryavtsev 07/23/2008 05:43AM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.