8.3.1 List of the methods in the Statement interface
- Organization of this subsection
(1) Main functions of the Statement interface
The Statement interface provides the following main functions:
-
Execution of SQL statements
-
Creation of a result set (ResultSet object) for retrieval results
-
Return of the number of updated rows as the result of updating
-
Specification of the maximum number of rows to be retrieved
-
Specification of a retrieval limit time
(2) Methods in the Statement interface that are supported by HADB
The following table lists and describes the methods in the Statement interface that are supported by HADB.
No. |
Method in the Statement interface |
Function |
---|---|---|
1 |
Adds SQL statements to the Statement object's batch. |
|
2 |
Cancels the SQL statements executing in the corresponding object and in objects using the same connection as that object. |
|
3 |
Clears all SQL statements registered in this Statement object's batch. |
|
4 |
Clears all warnings that have been reported for this Statement object. |
|
5 |
Closes the Statement object and any ResultSet object created from this Statement object. |
|
6 |
Closes this Statement object when all result sets that depend on the Statement object are closed. |
|
7 |
Executes an SQL statement. |
|
8 |
Executes the SQL statements registered in a batch and returns the number of updated rows as int data in an array. |
|
9 |
Executes the SQL statements registered in a batch and returns the number of updated rows as long data in an array. |
|
10 |
Executes an SQL statement (other than a retrieval SQL statement) and returns the number of updated rows as long data. |
|
11 |
Executes a retrieval SQL statement and returns a ResultSet object containing the retrieval result. |
|
12 |
Executes an SQL statement (other than a retrieval SQL statement) and returns the number of updated rows as int data. |
|
13 |
Returns the Connection object that created the Statement object. |
|
14 |
Acquires the default fetch direction for a result set that is created from this Statement object. |
|
15 |
Acquires the default fetch size (number of retrieval result rows to be transferred from the HADB server to the HADB client in the batch mode) for a ResultSet object that is created from the Statement object. |
|
16 |
Acquires the SQL statement sequence number that is assigned to this Statement object. |
|
17 |
Acquires the statement handle that is assigned to this Statement object. |
|
18 |
Acquires the maximum number of rows that can be stored in a ResultSet object created from this Statement object as long data. |
|
19 |
Returns the number of updated rows as long data. |
|
20 |
Acquires the maximum number of bytes for a CHAR or VARCHAR column of a ResultSet object that is created by this Statement object. |
|
21 |
Acquires the maximum number of rows that can be stored in a ResultSet object created from this Statement object as int data. |
|
22 |
Moves to the next result set. |
|
23 |
Acquires the timeout time set for SQL processing in the setQueryTimeout method. |
|
24 |
Acquires retrieval results as a ResultSet object. |
|
25 |
Acquires the concurrent processing mode for a ResultSet object that is created from this Statement object. |
|
26 |
Acquires the holdability of the ResultSet object that is created from this Statement object. |
|
27 |
Acquires the result set type of a ResultSet object that is created from this Statement object. |
|
28 |
Returns the number of updated rows as int data. |
|
29 |
Acquires the first warning that is reported by a call related to this Statement object. |
|
30 |
Acquires a value indicating whether this Statement object is closed. |
|
31 |
Acquires a value that indicates whether this Statement object is closed when all result sets that depend on the object are closed. |
|
32 |
Acquires a value indicating whether this Statement object can be pooled. |
|
33 |
Specifies the SQL cursor name to be used by the execute method of the next Statement object. |
|
34 |
Specifies whether escape syntax analysis by this Statement object is to be enabled or disabled. |
|
35 |
Specifies the fetch direction for a result set that is created from this Statement object. |
|
36 |
Specifies the default fetch size (number of retrieval result rows to be transferred from the HADB server to the HADB client in the batch mode) for a ResultSet object that is created from this Statement object. |
|
37 |
Sets the maximum number of rows that can be stored in a ResultSet object created from this Statement object, as long data. |
|
38 |
Specifies the maximum number of bytes for a CHAR or VARCHAR column in a ResultSet object that is created from this Statement object. |
|
39 |
Sets the maximum number of rows that can be stored in a ResultSet object created from this Statement object, as int data. |
|
40 |
Specifies the SQL processing timeout value. |
- Important
-
HADB does not support methods that are not listed in this table. If an unsupported method is executed, an SQLException might be thrown.
(3) Required package name and class name
The package and class names required in order to use the Statement interface are as follows:
-
Package name: com.hitachi.hadb.jdbc
-
Class name: AdbStatement