What are stored procedures? How to call them?

Answer Posted / hazarath k

Stored Procedure is a set of precompiled SQL statements
(i.e., ready for execution), which will be executed at
Database server(backend).
By using the Callable Statement,We can call the Stored
Procedure from front-end.Callable is an interface.Every
vendor can provide their own implementation classes for
this intercace.By using this Callable Statement, we can
call the Stored Procedure/Stored Function.

Ex/Syntax:
Connection con=DriverManager.getConnection("---
","UID","PWD");
CallableStatement cstmt=con.prepareCall('{call
ProcedureName}');

Is This Answer Correct ?    2 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Why can't Tomcat find my Oracle JDBC drivers in classes111.zip?

572


Why is odbc needed?

495


What does the jdbc resultset interface?

530


How to get the Database server details in java program?

573


How can you make the connection using jdbc?

562






What are the jdbc api components?

656


Compare jdbc and odbc and how is jdbc required in this context.

525


Where jdbc drivermanager class is used?

527


Is it possible to connect to multiple databases? Using single statement can we update or extract data from two or three or many databases?

588


How do I find ojdbc jar version?

496


What do you mean by metadata and why we are using it?

565


What are the considerations for deciding on transaction boundaries?

559


How to achieve JDBC Connection Pooling using JDBC DataSource and JNDI in Apache Tomcat Server?

531


How does jdbc driver work?

532


Explain about the drive manager class working?

604