GeekInterview.com
   Home |  Tech FAQ  |   Interview Questions |  Placement Papers |  Tech Articles |  Learn |  Freelance Projects |  Online Testing |  Geeks Talk |  Job Postings |  Knowledge Base | Site Search |  Add/Ask Question

GeekInterview.com  >  Interview Questions  >  J2EE  >  JDBC
Go To First  |  Previous Question  |  Next Question 
 JDBC  |  Question 47 of 135    Print  
Which of the following statement is false regarding call to stored procedure from JDBC.
A) Create a CallableStatement object.
B) A CallableStatement object contains a call to a stored procedure.
C) The execution call should be like CallableStatement cs = con.prepareCall("{call SHOW_SUPPLIERS}");
D) We need not make an instance of the Connection class before making a Callable statement.
Explanation: The callable statement is prepared based on the connection object only check option c, where con is an instance of the Connection object.



  
Total Answers and Comments: 1 Last Update: December 30, 2005   
  
 Sponsored Links

 
 Best Rated Answer

No best answer available. Please pick the good answer available or submit your answer.
December 30, 2005 09:24:59   #1  
krudupa9 Member Since: December 2005   Contribution: 8    

RE: Which of the following statement is false regardin...

Answer is D

We have to make a connection object as we call the method prepareCall() of connection object.


 
Is this answer useful? Yes | No

 Related Questions

Answered by Jey on 2005-05-10 05:53:50: 1.Statement which is used to run simple sql statements like select and update 2. PrepareStatment is used to run Pre compiled sql.  3. CallableStatement 
Latest Answer : Load the driver class using class.forName(driverclass) and class.forName() loads the driver class and passes the control to DriverManager class ...

Latest Answer : Stored procedure contains set of sQL Statements thar are executed in the database by the sql stament processor.code:DECLARE NUM1 NUMBER:=10; NUM2 NUMBER:=20;BEGIN    DBMS_OUTPUT.PUT_LINE('sum:'||To_Char(NUM1+NUM2,'999.99'));END; ...

Answered by Jey on 2005-05-10 06:01:10: Here are the steps.  Using DriverManager: 1. Load the driver class using class.forName(driverclass) and class.forName() loads the driver class and 
Latest Answer : First we register the connection and after that we connect the database, in that we give to which database is connecting giving that  ipaddress ,port number,username and password . ...

Latest Answer : Also JDBC2.0 provides extended support for transactions that includes batch updates and savepoints ...

JDBC is a layer of abstraction that allows users to choose between databases. It allows you to change to a different database engine and to write to a single API. JDBC allows you to write database applications 
Latest Answer : JDBC is a core API of Java 1.1 and later which provides a standard set of interfaces to SQL-compliant databases. ...

One implementation interface for database manufacturers, the other implementation interface for application and applet writers. 
Latest Answer : JDBC has four major components:1.The JDBC API2.The JDBC Driver Manager3.The JDBC Test Suite4.The JDBC-ODBC Bridge      The first two components of JDBC,the JDBC API and the JDBC Driver Managermanages to connect to the database ...

The JDBC Driver interface provides vendor-specific implementations of the abstract classes provided by the JDBC API. Each vendors driver must provide implementations of the java.sql.Connection,Statement,PreparedStatement, 
Latest Answer : As has been mentioned above, the implementations are provided by the database vendors like for example, the classes12.jar of oracle which has the implementations. ...

Create an instance of a JDBC driver or load JDBC drivers through jdbc.driversRegister a driverSpecify a databaseOpen a database connectionSubmit a queryReceive results 
Latest Answer : import java.sql.*;class Type1 { public static void main(String[] args)throws Exception {  Connection c=null;  try  {    Driver d=new Driver("sun.jdbc.odbc.JdbcOdbc");     //or  ...

There are 8 packages: java.sql.Driver, Connection,Statement, PreparedStatement, CallableStatement, ResultSet, ResultSetMetaData, DatabaseMetaData. 
Latest Answer : Packages arejava.sql and javax.sql only..Those mentioned in the previous lists are the classes & interfaces in those packages. ...

A URL string -->getConnection-->DriverManager-->Driver-->Connection-->Statement-->executeQuery-->ResultSet. 
Latest Answer : 1). Register the Driver 2) load the Driver 3)get the connection 4) create the statement 5) Execute the query 6) fetch the results with ResultSet ...


 Sponsored Links

 
Related Articles

What are the differences between stored procedures and triggers?

Stored procedures are compiled collection of programs or SQL statements that live in the database. A stored procedure can access and modify data present in many tables. Also a stored procedure is not associated with any particular database object. But triggers are event-driven special procedures whi
 

How does the function call within function get evaluated?

Whenever we have more than one function which is called for a finite number of times then such a function gets evaluated from inside out. Let us understand this concept with an example. For instance consider a function sample called within it 4 times as given in program below: main() { int a=50;
 

How to call C header that is not provided generally by system in C++?

Headers can be called by using extern C Syntax of extern C is: extern "C" <function declaration> for example to call C functions from C++ we can write extern "C" { <function declaration> <function declaration> ...
 

What is difference between call by value and call by reference in function?

The arguments passed to function can be of two types 1. Values passed 2. Address passed The first type refers to call by value and the second type refers to call by reference. For instance consider program1 main() { int x=50, y=70; interchange(x,y); printf(“x=%d y=%d”,x,
 

What are the limitations with switch statement?

Switch statement is a powerful statement used to handle many alternatives and provides good presentation for C program. But there are some limitations with switch statement which are given below: Logical operators cannot be used with switch statement. For instance case k>=20: is not allowe
 

goto Statement

Why to avoid goto in C C has goto statement but one must ensure not to use too much of goto statement in their program because its functionality is limited and it is only recommended as a last resort if structured solutions are much more complicated. First let us understand the goto statement, its
 

The Interview Snafu

How to turn someone else’s mistake to your advantage Your dream job is about to become reality. A recruiter gave you the heads up about the perfect position at Humungous Conglomerate, Inc. You went through five interviews as well as a battery of psychological tests mandated by their HR de
 

Winning a Job Interview with a Winning Resume

Does your resume unlock your potential, take your skills to the highest level and win you the interview and the job you want now? The job market today is highly competitive and even if you think you have what it takes to get an interview you won’t get over the line without a polished, prof
 

XML Remote Calling Procedure

XML Remote Calling Procedure XML RPC or the XML Remote Calling Procedure is a set of compilations and implementations which allow certain programs to run on complex platforms or operating systems and allows them to make Remote Procedure calls on the Internet The Remote Procedure Calling Protocol use
 

Importance of Proper English during Job Interview

Importance of Proper English during Job Interview Your job interview is crucially important and it will determine whether or not you will get the job Depending on the type of job you re going for it is very important for you to use proper English In most cases jobs which offer higher salaries will h
 





About Us  |   Privacy Policy  |   Terms and Conditions  |   Contact  |   Site Map  |   Add Question  |   Propose Category  |   RSS Feeds  |   Articles Sitemap  |   Site Updates  |   Add Resource

Copyright © 2005 - 2008 GeekInterview.com. All Rights Reserved
Page copy protected against web site content infringement by Copyscape