View Single Post

  #1 (permalink)  
Old 08-19-2004, 03:29 PM
banuchithrak banuchithrak is offline
Junior Member
 
Join Date: Jul 2004
Posts: 7
banuchithrak
Difference between Statement and Callable Stmt.

Hello everybody,
Please clear my following doubt :
I use java.sql.Statement object to call a stored procedure.
Eg :
ResultSet res = stmt.executeQuery(\"select now()\");

This returns me the current database time.

If this is the case, why should I go for a Callable Statement?

It is used exclusively used to call stored procedures. I f I can call the stored procedure through a Statement object, why should there be a Callable Statement?
Reply With Quote