31.) Which method allows you to set a timeout for a JDBC query?
A) setQueryTimeout()
B) setStatementTimeout()
C) setConnectionTimeout()
D) JDBC does not support query timeouts
32.) In JDBC, what is the purpose of the ResultSetMetaData interface?
A) To retrieve data from a result set
B) To retrieve metadata about the result set, such as column names and types
C) To execute SQL statements
D) To handle transactions
33.) What is a batch update in JDBC?
A) A method for updating database schema
B) A process for executing multiple SQL statements as a single unit
C) An optimized query for retrieving data
D) A way to establish a JDBC connection
34.) How can you execute a batch update in JDBC?
A) By using a ResultSet object
B) By calling the executeBatch() method of a Statement object
C) By using a PreparedStatement
D) By calling the executeUpdate() method multiple times
35.) What is metadata in the context of JDBC?
A) Data stored in a database table
B) Information about the database, such as its name and version
C) The result set of a SQL query
D) Data encryption in JDBC connections
36.) What does the JDBC DatabaseMetaData interface provide?
A) Information about the database driver
B) Information about the JDBC API
C) Information about the database, such as tables, columns, and schemas
D) Information about SQL query performance
37.) What is a SQL join in the context of databases and JDBC?
A) A database connection string
B) A technique for optimizing SQL queries
C) A way to combine data from multiple database tables
D) A method for executing SQL statements in parallel
38.) Which type of SQL join returns only the rows with matching values in both tables?
A) INNER JOIN
B) LEFT JOIN
C) RIGHT JOIN
D) FULL JOIN
39.) What is the purpose of the ResultSet.TYPE_SCROLL_INSENSITIVE constant in JDBC?
A) To disable scrolling through a result set
B) To enable scrollable and insensitive result sets
C) To specify the cursor type for a statement
D) To specify the fetch direction for a result set
40.) Which method allows you to update rows in a JDBC result set?
A) updateRow()
B) insertRow()
C) deleteRow()
D) modifyRow()