This week's book giveaway is in the OCMJEA forum.
We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line!
See this thread for details.
The moose likes JDBC and the fly likes How to store Output variables of a Stored Procedure in java Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "How to store Output variables of a Stored Procedure in java" Watch "How to store Output variables of a Stored Procedure in java" New topic
Author

How to store Output variables of a Stored Procedure in java

Sankha Ray
Greenhorn

Joined: May 01, 2010
Posts: 6
Hi , i am writting a java program which will call a Stored procedure.

The Stored Procedure will -1.populate a staging table
2. return 2 output variables(both are integers)

Any help on how to store these 2 variables in the java program?Because i am seeing that the prepareCall() method is returning a resultset ,which i clearly don't need.
Christophe Verré
Sheriff

Joined: Nov 24, 2005
Posts: 14687
    
  16

Check this JDBC guide.


[My Blog]
All roads lead to JavaRanch
Sankha Ray
Greenhorn

Joined: May 01, 2010
Posts: 6
Hi , i went through the document. But if i want to return a boolean value from the stored procedure , how the mapping will be done?I saw the bit datatype....but could not understand the concept.
Can you help me in understanding it ?
 
jQuery in Action, 2nd edition
 
subject: How to store Output variables of a Stored Procedure in java