Re: Need java.sql.Array impl for PreparedStatement.setArray()
Posted by: sam504u
Date: January 11, 2006 04:12PM

> Setup a prepared statement that has as many ?s as
> your largest array, set all of the values to null
> first, then set the first "n" values to the value
> in your array.

How do you know what is the size of the largest Array ??? In dynamic applications ... the number of elements will vary from call to call.

I have been looking for a way to call a SP using CallableStatement in Java wherein I can pass an array of Integers (or String) For Ex: int array[] = {1,2,3};

for the same purpose as tauron before was mentioning how do we do

SELECT id FROM table WHERE x IN (1,2,3) ???

-Sam

Options: ReplyQuote




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.