I am using a Callable Statement for calling the stored proc. But instead of passing a single value as a parameter ( I only have a single parameter), I want to send an array. Oracle stored procs can receive arrays as input parameters. Is there any way of doing that without using loops?.
Thanks for your help !!
Originally posted by Raajesh Chandran:
I can't get U what U really wants.Instead of Using single statment.Try to use the callable Statement inside the forloop.Hope it will work.If U want that coding sample let me know.I will send it to U.
Am trying to do the same operation - i.e.
Passing an array of strings (single dimension array) to an oracle stored proc.
I also get a ClassCastException when I create the ArrayDescriptor object..
The application is running on JRUN and the connection is obtained from a connection pool using DBCP connection pooling resources(org.apache.commons.dbcp.PoolableConnection).
I know that a bug exists in Oracle 8.1.7 while trying to connect with Websphere - does anyone know if this bug also exists when using DBCP pools?
Here is my code (strArray is a simple string array), which fails when trying to create the ArrayDescriptor :
ArrayDescriptor descriptor = ArrayDescriptor.createDescriptor( "p_array", con );
ARRAY array_to_pass = new ARRAY( descriptor, con, strArray );
Any help will be greatly appreciated.