how to use CallableStatement?
specially how to use their index given ..

Answer Posted / suresh

CallableStatement object is used to call the stored
procedure and stored procedure is nothing but it's block of
code and it's identified unique name

ex

CallableStatement cs=con.prepareCall();
cs.executeUpdate(Call"{procedure name}");


con is a Connection object
It has three parameter

IN
OUT
INOUT

IN parameter used to store any value to stored procedure
using setXX() method..

OUT parameter used to get the information or values from the
stored procedure using getXX() method,that object to
registered using registerOutParameter()

INOUT used to both store and get the information...

Is This Answer Correct ?    7 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the basic exceptions in jdbc?

721


What is the function of drivermanager class?

782


How can I get or redirect the log used by DriverManager and JDBC drivers?

690


How java can be connected to a database?

765


Result set’s index starts with 0 or 1?

733


what is the meaning of following code snippets Class c=class.forName(driverClassName); Driver d=(driver)c.newInstance();

4661


Why is jdbc used?

680


Differentiate between type_scroll_insensitive and type_scroll_sensitive.

703


What is jdbc connection interface?

701


What is jdbc class forname?

683


What is the difference between execute, executeQuery, executeUpdate?

732


What is “dirty read” in JDBC? Which isolation level prevents dirty read?

759


What is the use of statement in jdbc?

661


What is jdbc driver manager?

673


What is connection pooling and why it is used?

690