-
What are the flow statements of JDBC?
A URL string -->getConnection-->DriverManager-->Driver-->Connection-->Statement-->executeQuery-->ResultSet.
-
How to Make Updates to Updatable Result Sets?
Another new feature in the JDBC 2.0 API is the ability to update rows in a result set using methods in the Java programming language rather than having to send an SQL command. But before you can take advantage of this capability, you need to create a ResultSet object that is updatable. In order to do this, you supply the ResultSet constant CONCUR_UPDATABLE to the createStatement method.E.g.Connection...
-
How can you use PreparedStatement?
This special type of statement is derived from the more general class, Statement. If you want to execute a Statement object many times, it will normally reduce execution time to use a PreparedStatement object instead. The advantage to this is that in most cases, this SQL statement will be sent to the DBMS right away, where it will be compiled. As a result, the PreparedStatement object contains not...
-
State true or false .Does the JDBC-ODBC Bridge support multiple concurrent open statements per connection ?
A) TrueB) FalseExplanation: You can open only one Statement object per connection when you are using the JDBC-ODBC Bridge.
-
Which of the following statements is true regarding the two tier model of the JDBC driver model.
A) In this java applications interact directly with the database.B) A JDBC driver is required to communicate with the particular database management system that is being accessed.C) This model is referred to as the client/server configuration where user is the client and the machine that has the database is called the user.D) All of the above.
-
Which of the following statement is false regarding the different type of statements in JDBC
A) Regular Statement (use createStatement method)B) Prepared statement (use prepareStatement method)C) Callable statement (use prepareCall).D) Interim statement (use jdbcCall).
-
-
JDBC Type1 drivers
Can we use Type1 driver in web Application?If possible give me a simple example for all driver types?
-
-
-
Which Driver is preferable for using JDBC API in Applets.
A) Type - 1B) Type - 2C) Type - 3D) Type – 4
-
Which of the following is true regarding the use of the JDBC-ODBC bridge with the applets.
A) Use of the JDBC-ODBC bridge from an untrusted applet running in a browser, such as Netscape Navigator, isn't allowed.B) It is possible to use the JDBC-ODBC bridge with applets that will be run in appletviewer since appletviewer assumes that applets are trusted.C) It is not possible to use the JDBC-ODBC bridge with applets that are run in the HotJavaTM browser (available from Java Software), since...
-
Connection pooling concept through weblogic 8.1
Hi,I tried using connection pooling concept through weblogic 8.1 .import java.sql.*;import javax.naming.*;import javax.sql.DataSource;public class ConnectionpoolDemo { public static void main(String[] args) { try { InitialContext ic=new InitialContext(); Object obj=ic.lookup("MyDsJNDI"); DataSource ds=(DataSource)obj; Connection con=ds.getConnection(); Statement st=con.createStatement(); ResultSet...
-
Which of the following values can be replaced in the place of 1 and 2 belowStatement stmt = con.createStatement(1, 2);
A) ResultSet. TYPE_FORWARD_ONLY, ResultSet.CONCUR_READ_ONLYB) ResultSet. TYPE_SCROLL_INSENSITIVE , ResultSet. CONCUR_UPDATABLEC) ResultSet. CONCUR_UPDATABLE,ResultSet. TYPE_SCROLL_SENSITIVED) ResultSet. CONCUR_UPDATABLE,ResultSet. TYPE_FORWARD_ONLY
-
-
-
Which of the following values can be replaced in the place of 1 and 2 below Statement
Which of the following values can be replaced in the place of 1 and 2 below Statement stmt= con.createStatement(1,2);a) ResultSet. TYPE_FORWARD_ONLY, ResultSet.CONCUR_READ_ONLYb) ResultSet. TYPE_SCROLL_INSENSITIVE, ResultSet.CONCUR_UPDATABLEc) ResultSet. CONCUR_UPDATABLE, ResultSet. TYPE_SCROLL_SENSITIVEd) ResultSet.CONCUR_UPDATABLE, ResultSet. TYPE_FORWARD_ONLY
-
What are the two major components of JDBC?
One implementation interface for database manufacturers, the other implementation interface for application and applet writers.
-
Changing function of a buttom.
Consider the following:-ID [_______]Name [_______]Marks [_______]NEW EDIT CLOSEThis is a form which I have made. What i need is When I click on NEW button, if textboxes should be cleared and the text on the NEW button should change to SAVE. the EDIT button should be disabled and CLOSE should change to CANCEL.I am able to change the text of the buttons using settext command...
-
JDBC Interview Questions
Ans