Hello Daniel,
if you did look at the JDBC documentation you would find out that setArray is a
special method for setting some special java.sql.Array data type. This type is
not
supported in MaxDB.
If you have an IN clause with a very variadic number of parameters, you
will probably not benefit that much from prepared statements and its
caching. But probably you have counts that appear very often, and so
- generating the statement with parameters specs instead of
the actual values
- setting the values as parameters
may be an option.
Regards
Alexander Schr�der
SAP DB, SAP Labs Berlin
> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
> Sent: Friday, January 14, 2005 11:31 AM
> To: [email protected]
> Subject: jdbc connection query cache
>
> Hi,
> I realized that the cache paramter that I can specify when I
> open a jdbc connection works very well.
> The first time execution of a perpareStatement() takes very
> long, but additional calls use the cached version.
> I have many queries that contain something like this ...
> where id in ( 1, 2, 3, 4, 5, 6 ) ...
> Until now, I compose this query from java which might lead to
> problems with this caching because the parameter count
> changes and so the query might not be found in the cache.
> Would it help to change it to ... where id in ( ? ) and then
> call PreparedStatement.setArray(1, integerArray) ?
> bye
>
> Daniel
>
> --
> MaxDB Discussion Mailing List
> For list archives: http://lists.mysql.com/maxdb
> To unsubscribe:
> http://lists.mysql.com/[EMAIL PROTECTED]
>
>
>
--
MaxDB Discussion Mailing List
For list archives: http://lists.mysql.com/maxdb
To unsubscribe: http://lists.mysql.com/[EMAIL PROTECTED]