java - Passing object types to Oracle stored procedure gives "Invalid name pattern" error -


oracle database administrator provided me stored procedure. takes (in) varchar , supplies record type. record type follows:

type bal_record_type record (   ac_no               varchar2 (50),   account_type        varchar2 (50),   ac_status           varchar2 (10),   cur_code            varchar2 (5),   available_balance   number ); 

i've followed link below support record type in jdbc application. http://betteratoracle.com/posts/31-passing-record-types-between-oracle-and-java

from above article i've changed

stmt.registeroutparameter(2, oracletypes.struct, "rectype"); 

to

stmt.registeroutparameter(2, oracletypes.struct, "bal_record_type"); 

as bal_record_type record name.

but i'm getting following error:

invalid name pattern: appadmin.bal_record_type 

here appadmin username of database. don't know how binding out parameter.

my questions are:

  1. is there example code can follow support record type of oracle?

  2. what possible reason of error (invalid name pattern: appadmin.bal_record_type)?

addition:

  1. how difficult implement cursor type instead of record type oracle database administrator?

i've found issue. actually, not in part. our oracle db administrator defined type inside package not accessible java.

here excerpt: can't call type defined inside package in oracle. java can't access type, sqlplus can access. so, our db administrator defined type outside of package.

i've found solution here:

http://forum.spring.io/forum/spring-projects/data/34668-array-as-out-parameter-java-sql-sqlexception-ora-06550-line-1-column-7


Comments

Popular posts from this blog

Email notification in google apps script -

c++ - Difference between pre and post decrement in recursive function argument -

javascript - IE11 incompatibility with jQuery's 'readonly'? -