Skip to main content

Web Design and Development MCQs with Answers

Practice important Web Design and Development MCQs with answers and explanations.

Multiple Choice Questions

Q241: What does a ResultSet contain in Java?
  • A: A database connection
  • B: A table schema
  • C: The results of a SQL query
  • D: A SQL query
View Answer
C

Q242: How does a default ResultSet object behave?
  • A: It is updatable and scrollable
  • B: It is forward-only and not updatable
  • C: It is read-only and scrollable
  • D: It can be updated but not scrolled
View Answer
B

Q243: Which method is used to move the cursor to the next row in a ResultSet?
  • A: getRow()
  • B: moveToInsertRow()
  • C: previous()
  • D: next()
View Answer
D

Q244: The _______ method must be implemented by all threads.
  • A: wait()
  • B: start()
  • C: stop()
  • D: run()
View Answer
D

Q245: What does the next() method of ResultSet return?
  • A: The current row number
  • B: A boolean indicating if there is a next row
  • C: The data in the current row
  • D: The previous row's data
View Answer
B

Q246: What is the purpose of the close() method in ResultSet?
  • A: To release JDBC and database resources
  • B: To retrieve data from the ResultSet
  • C: To update the ResultSet
  • D: To move the cursor to the previous row
View Answer
A

Q247: What does the absolute(int row) method do in a ResultSet?
  • A: Moves the cursor to the specified row number
  • B: Moves the cursor to the previous row
  • C: Moves the cursor to the first row
  • D: Moves the cursor to the last row
View Answer
A

Q248: Which of these can be used to identify a thread?
  • A: Thread Id
  • B: Thread Name
  • C: Thread Priority
  • D: All of the above
View Answer
D

Q249: Which of these can be used to serialize an object?
  • A: FileOutputStream
  • B: ObjectOutputStream
  • C: ObjectInputStream
  • D: FileInputStream
View Answer
B

Q250: Which of these is a correct statement about a thread?
  • A: start() method waits until run() method finishes
  • B: run() method waits until start() method finishes
  • C: start() method creates a new thread and calls code written inside run() method
  • D: start() method returns the result to run() method
View Answer
C

Test Your Knowledge

Take a timed quiz on Web Design and Development

🚀 Start Quiz Now