Given:



Item table

ID, INTEGER: PK
DESCRIP, VARCHAR(100)
PRICE, REAL
QUANTITY, INTEGER

And given the code fragment:

Assume that:

The required database driver is configured in the classpath.
The appropriate database is accessible with the dbURL, userName, and passWord exists.
The SQL query is valid.

What is the result?

A. An exception is thrown at runtime.
B. Compilation fails.
C. The code prints Error.
D. The code prints information about Item 110.

題解

ResultSet物件的getX方法所傳入的欄位名稱參數是不區分大小寫的,所以如果ID = 110的Item資料列存在的話,就會輸出該列的資訊。