File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Calling stored procedures from JSP

 
sunil kumre
Ranch Hand
Posts: 64
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is it possible to call stored procedures from a Jsp file?How?
thanks in advance.
sunil
 
prabhatis
Greenhorn
Posts: 18
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
try this ..
Connection con = getConnection();
CallableStatement cs = con.prepareCall("{? = call X2K.pkgQuotes.CHECKEXPIRATION(?, ?, ?)}");
cs.registerOutParameter(1, java.sql.Types.OTHER);
cs.setString(2, rootSymbol );
cs.setString(3, futureOption);
cs.setString(4, exchangeCode);
cs.execute();
rs = (ResultSet)cs.getObject(1);
while ( rs.next() )
{}
hope u can figure it out
if not ...just ask i'll be hapy to clarify
Prabhat
 
Frank Carver
Sheriff
Posts: 6920
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"prabhatis",
The Java Ranch has thousands of visitors every week, many with surprisingly similar names. To avoid confusion we have a naming convention, described at http://www.javaranch.com/name.jsp . We require names to have at least two words, separated by a space, and strongly recommend that you use your full real name. Please log in with a new name which meets the requirements.
Thanks.
 
prabhatis
Greenhorn
Posts: 18
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
thanx for reminding..
i am going to reregister my serf as prabhat kumar will this do ??
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic