0% found this document useful (0 votes)
22 views2 pages

Ajp MCQ Set 2 (1)

Uploaded by

sanskrutinile06
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
22 views2 pages

Ajp MCQ Set 2 (1)

Uploaded by

sanskrutinile06
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

SET 2

Sr
Question Option A Option B Option C Option D Answer
No
returns the port returns the port
returns the port returns the server
number on number on which
int getServerPort() method name on which number on which
1 which this this d
____________ the request was this request was
request was response/request
received. received.
received. was received.
In this constructor ServerSocket(int
2 port, int max_queue) what is the 100 50 75 80 a
default value for max_queue?

Select the method used to create open


3 URL Connection URL URL Decoder b
URL connection. Connection

Which of the following type of JDBC JDBC‐ODBC Native‐API,


JDBC‐Net, pure Native‐protocol,
4 driver, is also called Type 2 JDBC Bridge plus partly Java b
Java driver pure Java driver
driver? ODBC driver driver

Which of the following holds data


retrieved from a database after you
5 ResultSet JDBC driver Connection Statement a
execute an SQL query using
Statement objects?
Which package provides core
6 java.net java.rmi java.lang java.math c
functionality?
Sequential Structured Sequential
Structured
7 SQL stands for __________. Query Question Question A
Query Language
Language Language Language

_____________ is a table of data ResultSetMeta


8 MetaData ResultSet Statement C
which represents a data from table. Data

Public class DriverManager extends


9 Object String Connection Statement A
____________.

Which of the following method is


10 used to perform DML statements in executeResult() executeQuery() executeUpdate() execute() C
JDBC?

How many transaction isolation


11 levels provide the JDBC through the 3 4 7 2 B
Connection interface?
Which package in Java contains the
12 java.sql java.jdbc java.db java.connection A
JDBC classes?

In JDBC, which interface is


13 responsible for making a connection Driver Connection Statement ResultSet B
to the database?

Which of the following is used to PreparedStateme


14 DriverManager Connection ResultSet D
execute SQL queries in JDBC? nt

Session is part of the


SessionTracking and is for
15 TRUE FALSE None All A
maintaining the client state at the
server side.

Which of the following is NOT a 500 Internal


16 200 OK 300 Redirect 400 Bad Request B
valid HTTP status code? Server Error

Web server is used for loading the


17 TRUE FALSE None All A
init() method of a servlet.

After filter
When is destroy() method of a filter End of filter Beginning of filter After filter
18 executed A
called? lifecycle lifecycle executed
doFilter()

Web server is used for loading init()


19 TRUE FALSE None All A
method of servlet?

Which HTTP method is used to


20 retrieve data from the server in a GET POST PUT DELETE A
safe way?

You might also like