File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JDBC and the fly likes How to understand which datatype is being output from a stored procedure Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "How to understand which datatype is being output from a stored procedure " Watch "How to understand which datatype is being output from a stored procedure " New topic
Author

How to understand which datatype is being output from a stored procedure

Shantanu Deshmukh
Greenhorn

Joined: Jul 28, 2011
Posts: 23

Hello,
I am trying to write a function which takes stored procedure's name and it's arguments as argument and execute it.
Now I want that, the function should be able to know wat data is being output from the sp, so I can set datatype of output variable of sp.

How to do this ?


There are no failures, only experiences
Fatih Keles
Ranch Hand

Joined: Sep 01, 2005
Posts: 182
Hi Shantanu,

I guess you have to look up for your procedure in database metadata and learn about it in details. But there are many things to be considered like how many and what types of arguments does the procedure have? How to handle CLOB, BLOB and raw types? What about UDTs?

You are on a dark path, good luck with that

I am sure some other rancher will give a hand.

Regards,
Fatih.
 
Consider Paul's rocket mass heater.
 
subject: How to understand which datatype is being output from a stored procedure
 
Similar Threads
problem executing callableStatement...
How <sql-update> will map with the parameters
executeUpdate() returning unexpected results
Boolean datatype
Problem with Stored Procedures