db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dimple Bhatia" <dim...@gmail.com>
Subject Fwd: Passing in objects to Stored procedures
Date Fri, 05 Oct 2007 18:42:51 GMT
Hello,
Could someone pls. help me with my question below.
Thanks
Dimple


---------- Forwarded message ----------
From: Dimple Bhatia <dimp20@gmail.com>
Date: Oct 2, 2007 10:32 PM
Subject: Passing in objects to Stored procedures
To: derby-dev <derby-dev@db.apache.org>


Hi,
I am trying to create a database side procedure(procedure will be created
when the database is created) but the input parameter needs to be an object
of some class X that I have. I tried to d that and for the arg type,I
specified "

TypeDescriptor[] arg_types = {

DataTypeDescriptor.*getSQLDataTypeDescriptor*(

"Table")

};"

Where Table is the nam eof the Java class who object I will be passing in
when calling the store dprocedure.

But when issuing the preareCall(), I get a null pointer execpetion in

TypeId typeId = TypeId.*getBuiltInTypeId*(td.getJDBCTypeId());

in resolveRoutine().

I thought we are allowed to pass in Java objects to stored procedures but
the *getBuiltInTypeId returns null* since it does include the JAVA_OBJECT
type id.

Can we create and call java store dprocedures which can take in objects of a
class?

if so, can someone help with what I maybemissing here.

Thanks

Dimple.

Mime
View raw message