My Oracle Support Banner

Repeated Calls of a PL/SQL Procedure That Takes an ARRAY Argument Are Slow in JDBC 10.2. (Doc ID 1097053.1)

Last updated on JULY 27, 2019

Applies to:

JDBC - Version to [Release 10.2]
Information in this document applies to any platform.
***Checked for relevance on 21-Oct-2011***


A java application that connects to a database via JDBC/Thin repeatedly calls a PL/SQL stored procedure that takes an ARRAY argument. The relevant Java code is:

ArrayDescriptor desc = ArrayDescriptor.createDescriptor("Emp", conn);
ARRAY newarray = new ARRAY(desc,conn,usrprofiles.toArray());
OracleCallableStatement cstmt = (OracleCallableStatement)conn.prepareCall ("{ call Emp_Procedure( ? ) }");
cstmt.setARRAY (1, newarray);

This is slow, taking 10 secs for 40k of data.

SQL trace shows the following sql statement as many times as the array size.


To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!

In this Document

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.