Deck 7: JDBC and Networking
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Question
Unlock Deck
Sign up to unlock the cards in this deck!
Unlock Deck
Unlock Deck
1/25
Play
Full screen (f)
Deck 7: JDBC and Networking
1
Which of the following is false as far as type 4 driver is concern?
A)type 4 driver is "native protocol, pure java" driver
B)type 4 drivers are 100% java compatible
C)type 4 drivers uses socket class to connect to the database
D)type 4 drivers can not be used with netscape
A)type 4 driver is "native protocol, pure java" driver
B)type 4 drivers are 100% java compatible
C)type 4 drivers uses socket class to connect to the database
D)type 4 drivers can not be used with netscape
type 4 drivers can not be used with netscape
2
Which driver is efficient and always preferable for using JDBC applications?
A)type - 4
B)type - 1
C)type - 3
D)type - 2
A)type - 4
B)type - 1
C)type - 3
D)type - 2
type - 4
3
JDBC facilitates to store the java objects by using which of the methods ofPreparedStatementsetObject () 2. setBlob() 3. setClob()
A)1, 2
B)1,2,3
C)1,3
D)2,3
A)1, 2
B)1,2,3
C)1,3
D)2,3
1,2,3
4
The JDBC-ODBC bridge is
A)three tiered
B)multithreaded
C)best for any platform
D)all of the above
A)three tiered
B)multithreaded
C)best for any platform
D)all of the above
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
5
All raw data types (including binary documents or images) should be read and uploaded to the database as an array of
A)byte
B)int
C)boolean
D)char
A)byte
B)int
C)boolean
D)char
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
6
The class java. sql.Timestamp has its super class as
A)java.sql.time
B)java.util.date
C)java.util.time
D)none of the above
A)java.sql.time
B)java.util.date
C)java.util.time
D)none of the above
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
7
BLOB, CLOB, ARRAY and REF type columns can be updated in
A)jdbc 1.0
B)jdbc 4.0
C)jdbc 2.0
D)jdbc 3.0
A)jdbc 1.0
B)jdbc 4.0
C)jdbc 2.0
D)jdbc 3.0
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
8
Which of the following methods finds the maximum number of connections that a specific driver can obtain?
A)database.getmaxconnections
B)connection.getmaxconnections
C)databasemetadata)getmaxconnections
D)resultsetmetadata)getmaxconnections
A)database.getmaxconnections
B)connection.getmaxconnections
C)databasemetadata)getmaxconnections
D)resultsetmetadata)getmaxconnections
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
9
When the message "No Suitable Driver" occurs?
A)when the driver is not registered by class.forname() method
B)when the user name, password and the database does not match
C)when the jdbc database url passed is not constructed properly
D)when the type 4 driver is used
A)when the driver is not registered by class.forname() method
B)when the user name, password and the database does not match
C)when the jdbc database url passed is not constructed properly
D)when the type 4 driver is used
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
10
Which driver is called as thin-driver in JDBC?
A)type-4 driver
B)type-1 driver
C)type-3 driver
D)type-2 driver
A)type-4 driver
B)type-1 driver
C)type-3 driver
D)type-2 driver
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
11
How many trAnsweraction isolation levels are defined in java.sql.Connection interface?
A)4
B)3
C)5
D)2
A)4
B)3
C)5
D)2
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
12
Which method is used to perform DML statements in JDBC?
A)execute()
B)executequery()
C)executeupdate()
D)executeresult()
A)execute()
B)executequery()
C)executeupdate()
D)executeresult()
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
13
What is the disadvantage of Type-4 Native-Protocol Driver?
A)at client side, a separate driver is needed for each database.
B)type-4 driver is entirely written in java
C)the driver converts jdbc calls into vendor-specific database protocol
D)it does not support to read mysql data)
A)at client side, a separate driver is needed for each database.
B)type-4 driver is entirely written in java
C)the driver converts jdbc calls into vendor-specific database protocol
D)it does not support to read mysql data)
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
14
TCP,FTP,Telnet,SMTP are example of?
A)socket
B)ip address
C)protocol
D)mac address
A)socket
B)ip address
C)protocol
D)mac address
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
15
In Inetaddress class which method returns the host name of IP address?
A)public string gethostname()
B)public string gethostaddress()
C)public string inetaddress getlocalhost()
D)none
A)public string gethostname()
B)public string gethostaddress()
C)public string inetaddress getlocalhost()
D)none
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
16
Show some networking terminology given below?
A)all
B)ip address
C)protocol
D)mac address
A)all
B)ip address
C)protocol
D)mac address
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
17
Which classes are used for connection less socket programming?
A)datagram socket
B)datagram packet
C)both a and b
D)none
A)datagram socket
B)datagram packet
C)both a and b
D)none
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
18
how many ports TCP/IP are reserved for specific protocol?
A)10
B)1024
C)2048
D)512
A)10
B)1024
C)2048
D)512
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
19
how many bits are in a single IP address?
A)8
B)16
C)32
D)64
A)8
B)16
C)32
D)64
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
20
Which of these class is used to encapsulate IP address and DNS?
A)datagram packet
B)url
C)inetaddress
D)contenthandler
A)datagram packet
B)url
C)inetaddress
D)contenthandler
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
21
Which of these is return type of getAddress method of DatagramPacket class?
A)findaddress()
B)getaddress()
C)address()
D)whois()
A)findaddress()
B)getaddress()
C)address()
D)whois()
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
22
Which of these method of DatagramPacket is used to find port number?
A)port()
B)getport()
C)findport()
D)receivedport()
A)port()
B)getport()
C)findport()
D)receivedport()
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
23
Which of these class is necessary to implement datagrams?DNYANSAGAR ARTS AND COMMERCE COLLEGE, BALEWADI,PUNE - 45PROF . SUPRIYA MANE www.dacc.edu.in
A)datagrampacket
B)datagramsocket
C)all of the mentioned
D)none of the mentioned
A)datagrampacket
B)datagramsocket
C)all of the mentioned
D)none of the mentioned
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
24
Which of these method of DatagramPacket is used to find the port number?
A)port()
B)getport()
C)findport()
D)recieveport()
A)port()
B)getport()
C)findport()
D)recieveport()
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck
25
Which of these method of DatagramPacket is used to obtain the byte array of data contained in a datagram?
A)getdata()
B)getbytes()
C)getarray()
D)recievebytes()
A)getdata()
B)getbytes()
C)getarray()
D)recievebytes()
Unlock Deck
Unlock for access to all 25 flashcards in this deck.
Unlock Deck
k this deck