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 MARCH 08, 2017

Applies to:

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

Symptoms

A java application that connects to a database via JDBC/Thin 10.2.0.4 repeatedly calls a PL/SQL stored procedure that takes an ARRAY argument. The relevant Java code is:
ArrayDescriptor desc = ArrayDescriptor.createDescriptor("ESDBO.ARRTEST_TBL", conn);
ARRAY newarray = new ARRAY(desc,conn,usrprofiles.toArray());
OracleCallableStatement cstmt = (OracleCallableStatement)conn.prepareCall ("{ call arrtest_proc( ? ) }");
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.
SELECT INSTANTIABLE, supertype_owner, supertype_name, LOCAL_ATTRIBUTES
FROM
all_types WHERE type_name = :1 AND owner = :2

Cause

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
Symptoms
Cause
Solution


This document is being delivered to you via Oracle Support's Rapid Visibility (RaV) process and therefore has not been subject to an independent technical review.
My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.