I have a JDBC program to which uses a CallabaleStatement
object to set and register IN/OUT parameters for the stored procedure.
I have used ArrayDescriptor
s and oracle.sql.ARRAY
object and set it as an input parameter with the user-defined datatype.
The User defined datatype is TYPE CharArray1 IS TABLE OF CHAR(7)
. During the executing the error, I receive is "invalid pattern name my-object".
I set the input in the following way:
ArrayDescriptor ad = ArrayDescriptor.createDescriptor("<package-name>.CharArray1", conn);
ARRAY arr = new ARRAY(ad, conn, new String[]{"1"});
callableStatement.setArray(3, arr );
where conn
is my Connection
Object. I have checked the Execute permission for the package-name
for the Datatype CharArray1
. I have removed the package-name and checked, the error remain the same.
Thanks in advance. Please advise me as to what I'm doing wrong here.