1 /*
2  * Copyright (C) 2014 The Android Open Source Project
3  * Copyright (c) 1996, 2013, Oracle and/or its affiliates. All rights reserved.
4  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5  *
6  * This code is free software; you can redistribute it and/or modify it
7  * under the terms of the GNU General Public License version 2 only, as
8  * published by the Free Software Foundation.  Oracle designates this
9  * particular file as subject to the "Classpath" exception as provided
10  * by Oracle in the LICENSE file that accompanied this code.
11  *
12  * This code is distributed in the hope that it will be useful, but WITHOUT
13  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
14  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
15  * version 2 for more details (a copy is included in the LICENSE file that
16  * accompanied this code).
17  *
18  * You should have received a copy of the GNU General Public License version
19  * 2 along with this work; if not, write to the Free Software Foundation,
20  * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
21  *
22  * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
23  * or visit www.oracle.com if you need additional information or have any
24  * questions.
25  */
26 
27 package java.sql;
28 
29 import java.math.BigDecimal;
30 import java.util.Calendar;
31 import java.io.Reader;
32 import java.io.InputStream;
33 
34 /**
35  * A table of data representing a database result set, which
36  * is usually generated by executing a statement that queries the database.
37  *
38  * <P>A <code>ResultSet</code> object  maintains a cursor pointing
39  * to its current row of data.  Initially the cursor is positioned
40  * before the first row. The <code>next</code> method moves the
41  * cursor to the next row, and because it returns <code>false</code>
42  * when there are no more rows in the <code>ResultSet</code> object,
43  * it can be used in a <code>while</code> loop to iterate through
44  * the result set.
45  * <P>
46  * A default <code>ResultSet</code> object is not updatable and
47  * has a cursor that moves forward only.  Thus, you can
48  * iterate through it only once and only from the first row to the
49  * last row. It is possible to
50  * produce <code>ResultSet</code> objects that are scrollable and/or
51  * updatable.  The following code fragment, in which <code>con</code>
52  * is a valid <code>Connection</code> object, illustrates how to make
53  * a result set that is scrollable and insensitive to updates by others, and
54  * that is updatable. See <code>ResultSet</code> fields for other
55  * options.
56  * <PRE>
57  *
58  *       Statement stmt = con.createStatement(
59  *                                      ResultSet.TYPE_SCROLL_INSENSITIVE,
60  *                                      ResultSet.CONCUR_UPDATABLE);
61  *       ResultSet rs = stmt.executeQuery("SELECT a, b FROM TABLE2");
62  *       // rs will be scrollable, will not show changes made by others,
63  *       // and will be updatable
64  *
65  * </PRE>
66  * The <code>ResultSet</code> interface provides
67  * <i>getter</i> methods (<code>getBoolean</code>, <code>getLong</code>, and so on)
68  * for retrieving column values from the current row.
69  * Values can be retrieved using either the index number of the
70  * column or the name of the column.  In general, using the
71  * column index will be more efficient.  Columns are numbered from 1.
72  * For maximum portability, result set columns within each row should be
73  * read in left-to-right order, and each column should be read only once.
74  *
75  * <P>For the getter methods, a JDBC driver attempts
76  * to convert the underlying data to the Java type specified in the
77  * getter method and returns a suitable Java value.  The JDBC specification
78  * has a table showing the allowable mappings from SQL types to Java types
79  * that can be used by the <code>ResultSet</code> getter methods.
80  * <P>
81  * <P>Column names used as input to getter methods are case
82  * insensitive.  When a getter method is called  with
83  * a column name and several columns have the same name,
84  * the value of the first matching column will be returned.
85  * The column name option is
86  * designed to be used when column names are used in the SQL
87  * query that generated the result set.
88  * For columns that are NOT explicitly named in the query, it
89  * is best to use column numbers. If column names are used, the
90  * programmer should take care to guarantee that they uniquely refer to
91  * the intended columns, which can be assured with the SQL <i>AS</i> clause.
92  * <P>
93  * A set of updater methods were added to this interface
94  * in the JDBC 2.0 API (Java<sup><font size=-2>TM</font></sup> 2 SDK,
95  * Standard Edition, version 1.2). The comments regarding parameters
96  * to the getter methods also apply to parameters to the
97  * updater methods.
98  *<P>
99  * The updater methods may be used in two ways:
100  * <ol>
101  * <LI>to update a column value in the current row.  In a scrollable
102  *     <code>ResultSet</code> object, the cursor can be moved backwards
103  *     and forwards, to an absolute position, or to a position
104  *     relative to the current row.
105  *     The following code fragment updates the <code>NAME</code> column
106  *     in the fifth row of the <code>ResultSet</code> object
107  *     <code>rs</code> and then uses the method <code>updateRow</code>
108  *     to update the data source table from which <code>rs</code> was derived.
109  * <PRE>
110  *
111  *       rs.absolute(5); // moves the cursor to the fifth row of rs
112  *       rs.updateString("NAME", "AINSWORTH"); // updates the
113  *          // <code>NAME</code> column of row 5 to be <code>AINSWORTH</code>
114  *       rs.updateRow(); // updates the row in the data source
115  *
116  * </PRE>
117  * <LI>to insert column values into the insert row.  An updatable
118  *     <code>ResultSet</code> object has a special row associated with
119  *     it that serves as a staging area for building a row to be inserted.
120  *     The following code fragment moves the cursor to the insert row, builds
121  *     a three-column row, and inserts it into <code>rs</code> and into
122  *     the data source table using the method <code>insertRow</code>.
123  * <PRE>
124  *
125  *       rs.moveToInsertRow(); // moves cursor to the insert row
126  *       rs.updateString(1, "AINSWORTH"); // updates the
127  *          // first column of the insert row to be <code>AINSWORTH</code>
128  *       rs.updateInt(2,35); // updates the second column to be <code>35</code>
129  *       rs.updateBoolean(3, true); // updates the third column to <code>true</code>
130  *       rs.insertRow();
131  *       rs.moveToCurrentRow();
132  *
133  * </PRE>
134  * </ol>
135  * <P>A <code>ResultSet</code> object is automatically closed when the
136  * <code>Statement</code> object that
137  * generated it is closed, re-executed, or used
138  * to retrieve the next result from a sequence of multiple results.
139  *
140  * <P>The number, types and properties of a <code>ResultSet</code>
141  * object's columns are provided by the <code>ResultSetMetaData</code>
142  * object returned by the <code>ResultSet.getMetaData</code> method.
143  *
144  * @see Statement#executeQuery
145  * @see Statement#getResultSet
146  * @see ResultSetMetaData
147  */
148 
149 public interface ResultSet extends Wrapper, AutoCloseable {
150 
151     /**
152      * Moves the cursor froward one row from its current position.
153      * A <code>ResultSet</code> cursor is initially positioned
154      * before the first row; the first call to the method
155      * <code>next</code> makes the first row the current row; the
156      * second call makes the second row the current row, and so on.
157      * <p>
158      * When a call to the <code>next</code> method returns <code>false</code>,
159      * the cursor is positioned after the last row. Any
160      * invocation of a <code>ResultSet</code> method which requires a
161      * current row will result in a <code>SQLException</code> being thrown.
162      *  If the result set type is <code>TYPE_FORWARD_ONLY</code>, it is vendor specified
163      * whether their JDBC driver implementation will return <code>false</code> or
164      *  throw an <code>SQLException</code> on a
165      * subsequent call to <code>next</code>.
166      *
167      * <P>If an input stream is open for the current row, a call
168      * to the method <code>next</code> will
169      * implicitly close it. A <code>ResultSet</code> object's
170      * warning chain is cleared when a new row is read.
171      *
172      * @return <code>true</code> if the new current row is valid;
173      * <code>false</code> if there are no more rows
174      * @exception SQLException if a database access error occurs or this method is
175      *            called on a closed result set
176      */
next()177     boolean next() throws SQLException;
178 
179 
180     /**
181      * Releases this <code>ResultSet</code> object's database and
182      * JDBC resources immediately instead of waiting for
183      * this to happen when it is automatically closed.
184      *
185      * <P>The closing of a <code>ResultSet</code> object does <strong>not</strong> close the <code>Blob</code>,
186      * <code>Clob</code> or <code>NClob</code> objects created by the <code>ResultSet</code>. <code>Blob</code>,
187      * <code>Clob</code> or <code>NClob</code> objects remain valid for at least the duration of the
188      * transaction in which they are creataed, unless their <code>free</code> method is invoked.
189      *<p>
190      * When a <code>ResultSet</code> is closed, any <code>ResultSetMetaData</code>
191      * instances that were created by calling the  <code>getMetaData</code>
192      * method remain accessible.
193      *
194      * <P><B>Note:</B> A <code>ResultSet</code> object
195      * is automatically closed by the
196      * <code>Statement</code> object that generated it when
197      * that <code>Statement</code> object is closed,
198      * re-executed, or is used to retrieve the next result from a
199      * sequence of multiple results.
200      *<p>
201      * Calling the method <code>close</code> on a <code>ResultSet</code>
202      * object that is already closed is a no-op.
203      * <P>
204      * <p>
205      *
206      * @exception SQLException if a database access error occurs
207      */
close()208     void close() throws SQLException;
209 
210     /**
211      * Reports whether
212      * the last column read had a value of SQL <code>NULL</code>.
213      * Note that you must first call one of the getter methods
214      * on a column to try to read its value and then call
215      * the method <code>wasNull</code> to see if the value read was
216      * SQL <code>NULL</code>.
217      *
218      * @return <code>true</code> if the last column value read was SQL
219      *         <code>NULL</code> and <code>false</code> otherwise
220      * @exception SQLException if a database access error occurs or this method is
221      *            called on a closed result set
222      */
wasNull()223     boolean wasNull() throws SQLException;
224 
225     // Methods for accessing results by column index
226 
227     /**
228      * Retrieves the value of the designated column in the current row
229      * of this <code>ResultSet</code> object as
230      * a <code>String</code> in the Java programming language.
231      *
232      * @param columnIndex the first column is 1, the second is 2, ...
233      * @return the column value; if the value is SQL <code>NULL</code>, the
234      * value returned is <code>null</code>
235      * @exception SQLException if the columnIndex is not valid;
236      * if a database access error occurs or this method is
237      *            called on a closed result set
238      */
getString(int columnIndex)239     String getString(int columnIndex) throws SQLException;
240 
241     /**
242      * Retrieves the value of the designated column in the current row
243      * of this <code>ResultSet</code> object as
244      * a <code>boolean</code> in the Java programming language.
245      *
246      * <P>If the designated column has a datatype of CHAR or VARCHAR
247      * and contains a "0" or has a datatype of BIT, TINYINT, SMALLINT, INTEGER or BIGINT
248      * and contains  a 0, a value of <code>false</code> is returned.  If the designated column has a datatype
249      * of CHAR or VARCHAR
250      * and contains a "1" or has a datatype of BIT, TINYINT, SMALLINT, INTEGER or BIGINT
251      * and contains  a 1, a value of <code>true</code> is returned.
252      *
253      * @param columnIndex the first column is 1, the second is 2, ...
254      * @return the column value; if the value is SQL <code>NULL</code>, the
255      * value returned is <code>false</code>
256      * @exception SQLException if the columnIndex is not valid;
257      * if a database access error occurs or this method is
258      *            called on a closed result set
259      */
getBoolean(int columnIndex)260     boolean getBoolean(int columnIndex) throws SQLException;
261 
262     /**
263      * Retrieves the value of the designated column in the current row
264      * of this <code>ResultSet</code> object as
265      * a <code>byte</code> in the Java programming language.
266      *
267      * @param columnIndex the first column is 1, the second is 2, ...
268      * @return the column value; if the value is SQL <code>NULL</code>, the
269      * value returned is <code>0</code>
270      * @exception SQLException if the columnIndex is not valid;
271      * if a database access error occurs or this method is
272      *            called on a closed result set
273      */
getByte(int columnIndex)274     byte getByte(int columnIndex) throws SQLException;
275 
276     /**
277      * Retrieves the value of the designated column in the current row
278      * of this <code>ResultSet</code> object as
279      * a <code>short</code> in the Java programming language.
280      *
281      * @param columnIndex the first column is 1, the second is 2, ...
282      * @return the column value; if the value is SQL <code>NULL</code>, the
283      * value returned is <code>0</code>
284      * @exception SQLException if the columnIndex is not valid;
285      * if a database access error occurs or this method is
286      *            called on a closed result set
287      */
getShort(int columnIndex)288     short getShort(int columnIndex) throws SQLException;
289 
290     /**
291      * Retrieves the value of the designated column in the current row
292      * of this <code>ResultSet</code> object as
293      * an <code>int</code> in the Java programming language.
294      *
295      * @param columnIndex the first column is 1, the second is 2, ...
296      * @return the column value; if the value is SQL <code>NULL</code>, the
297      * value returned is <code>0</code>
298      * @exception SQLException if the columnIndex is not valid;
299      * if a database access error occurs or this method is
300      *            called on a closed result set
301      */
getInt(int columnIndex)302     int getInt(int columnIndex) throws SQLException;
303 
304     /**
305      * Retrieves the value of the designated column in the current row
306      * of this <code>ResultSet</code> object as
307      * a <code>long</code> in the Java programming language.
308      *
309      * @param columnIndex the first column is 1, the second is 2, ...
310      * @return the column value; if the value is SQL <code>NULL</code>, the
311      * value returned is <code>0</code>
312      * @exception SQLException if the columnIndex is not valid;
313      * if a database access error occurs or this method is
314      *            called on a closed result set
315      */
getLong(int columnIndex)316     long getLong(int columnIndex) throws SQLException;
317 
318     /**
319      * Retrieves the value of the designated column in the current row
320      * of this <code>ResultSet</code> object as
321      * a <code>float</code> in the Java programming language.
322      *
323      * @param columnIndex the first column is 1, the second is 2, ...
324      * @return the column value; if the value is SQL <code>NULL</code>, the
325      * value returned is <code>0</code>
326      * @exception SQLException if the columnIndex is not valid;
327      * if a database access error occurs or this method is
328      *            called on a closed result set
329      */
getFloat(int columnIndex)330     float getFloat(int columnIndex) throws SQLException;
331 
332     /**
333      * Retrieves the value of the designated column in the current row
334      * of this <code>ResultSet</code> object as
335      * a <code>double</code> in the Java programming language.
336      *
337      * @param columnIndex the first column is 1, the second is 2, ...
338      * @return the column value; if the value is SQL <code>NULL</code>, the
339      * value returned is <code>0</code>
340      * @exception SQLException if the columnIndex is not valid;
341      * if a database access error occurs or this method is
342      *            called on a closed result set
343      */
getDouble(int columnIndex)344     double getDouble(int columnIndex) throws SQLException;
345 
346     // Android-changed: Added reason to @deprecated to improve the documentation.
347     /**
348      * Retrieves the value of the designated column in the current row
349      * of this <code>ResultSet</code> object as
350      * a <code>java.sql.BigDecimal</code> in the Java programming language.
351      *
352      * @param columnIndex the first column is 1, the second is 2, ...
353      * @param scale the number of digits to the right of the decimal point
354      * @return the column value; if the value is SQL <code>NULL</code>, the
355      * value returned is <code>null</code>
356      * @exception SQLException if the columnIndex is not valid;
357      * if a database access error occurs or this method is
358      *            called on a closed result set
359      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
360      * this method
361      * @deprecated Use {@code getBigDecimal(int columnIndex)}
362      *             or {@code getBigDecimal(String columnLabel)}
363      */
364     // Android-added: @Deprecated annotation from OpenJDK8u121-b13 to fix build warnings.
365     @Deprecated
getBigDecimal(int columnIndex, int scale)366     BigDecimal getBigDecimal(int columnIndex, int scale) throws SQLException;
367 
368     /**
369      * Retrieves the value of the designated column in the current row
370      * of this <code>ResultSet</code> object as
371      * a <code>byte</code> array in the Java programming language.
372      * The bytes represent the raw values returned by the driver.
373      *
374      * @param columnIndex the first column is 1, the second is 2, ...
375      * @return the column value; if the value is SQL <code>NULL</code>, the
376      * value returned is <code>null</code>
377      * @exception SQLException if the columnIndex is not valid;
378      * if a database access error occurs or this method is
379      *            called on a closed result set
380      */
getBytes(int columnIndex)381     byte[] getBytes(int columnIndex) throws SQLException;
382 
383     /**
384      * Retrieves the value of the designated column in the current row
385      * of this <code>ResultSet</code> object as
386      * a <code>java.sql.Date</code> object in the Java programming language.
387      *
388      * @param columnIndex the first column is 1, the second is 2, ...
389      * @return the column value; if the value is SQL <code>NULL</code>, the
390      * value returned is <code>null</code>
391      * @exception SQLException if the columnIndex is not valid;
392      * if a database access error occurs or this method is
393      *            called on a closed result set
394      */
getDate(int columnIndex)395     java.sql.Date getDate(int columnIndex) throws SQLException;
396 
397     /**
398      * Retrieves the value of the designated column in the current row
399      * of this <code>ResultSet</code> object as
400      * a <code>java.sql.Time</code> object in the Java programming language.
401      *
402      * @param columnIndex the first column is 1, the second is 2, ...
403      * @return the column value; if the value is SQL <code>NULL</code>, the
404      * value returned is <code>null</code>
405      * @exception SQLException if the columnIndex is not valid;
406      * if a database access error occurs or this method is
407      *            called on a closed result set
408      */
getTime(int columnIndex)409     java.sql.Time getTime(int columnIndex) throws SQLException;
410 
411     /**
412      * Retrieves the value of the designated column in the current row
413      * of this <code>ResultSet</code> object as
414      * a <code>java.sql.Timestamp</code> object in the Java programming language.
415      *
416      * @param columnIndex the first column is 1, the second is 2, ...
417      * @return the column value; if the value is SQL <code>NULL</code>, the
418      * value returned is <code>null</code>
419      * @exception SQLException if the columnIndex is not valid;
420      * if a database access error occurs or this method is
421      *            called on a closed result set
422      */
getTimestamp(int columnIndex)423     java.sql.Timestamp getTimestamp(int columnIndex) throws SQLException;
424 
425     /**
426      * Retrieves the value of the designated column in the current row
427      * of this <code>ResultSet</code> object as
428      * a stream of ASCII characters. The value can then be read in chunks from the
429      * stream. This method is particularly
430      * suitable for retrieving large <code>LONGVARCHAR</code> values.
431      * The JDBC driver will
432      * do any necessary conversion from the database format into ASCII.
433      *
434      * <P><B>Note:</B> All the data in the returned stream must be
435      * read prior to getting the value of any other column. The next
436      * call to a getter method implicitly closes the stream.  Also, a
437      * stream may return <code>0</code> when the method
438      * <code>InputStream.available</code>
439      * is called whether there is data available or not.
440      *
441      * @param columnIndex the first column is 1, the second is 2, ...
442      * @return a Java input stream that delivers the database column value
443      * as a stream of one-byte ASCII characters;
444      * if the value is SQL <code>NULL</code>, the
445      * value returned is <code>null</code>
446      * @exception SQLException if the columnIndex is not valid;
447      * if a database access error occurs or this method is
448      *            called on a closed result set
449      */
getAsciiStream(int columnIndex)450     java.io.InputStream getAsciiStream(int columnIndex) throws SQLException;
451 
452     /**
453      * Retrieves the value of the designated column in the current row
454      * of this <code>ResultSet</code> object as
455      * as a stream of two-byte 3 characters. The first byte is
456      * the high byte; the second byte is the low byte.
457      *
458      * The value can then be read in chunks from the
459      * stream. This method is particularly
460      * suitable for retrieving large <code>LONGVARCHAR</code>values.  The
461      * JDBC driver will do any necessary conversion from the database
462      * format into Unicode.
463      *
464      * <P><B>Note:</B> All the data in the returned stream must be
465      * read prior to getting the value of any other column. The next
466      * call to a getter method implicitly closes the stream.
467      * Also, a stream may return <code>0</code> when the method
468      * <code>InputStream.available</code>
469      * is called, whether there is data available or not.
470      *
471      * @param columnIndex the first column is 1, the second is 2, ...
472      * @return a Java input stream that delivers the database column value
473      *         as a stream of two-byte Unicode characters;
474      *         if the value is SQL <code>NULL</code>, the value returned is
475      *         <code>null</code>
476      *
477      * @exception SQLException if the columnIndex is not valid;
478      * if a database access error occurs or this method is
479      *            called on a closed result set
480      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
481      * this method
482      * @deprecated use <code>getCharacterStream</code> in place of
483      *              <code>getUnicodeStream</code>
484      */
485     // Android-added: @Deprecated annotation from OpenJDK8u121-b13 to fix build warnings.
486     @Deprecated
getUnicodeStream(int columnIndex)487     java.io.InputStream getUnicodeStream(int columnIndex) throws SQLException;
488 
489     /**
490      * Retrieves the value of the designated column in the current row
491      * of this <code>ResultSet</code> object as a  stream of
492      * uninterpreted bytes. The value can then be read in chunks from the
493      * stream. This method is particularly
494      * suitable for retrieving large <code>LONGVARBINARY</code> values.
495      *
496      * <P><B>Note:</B> All the data in the returned stream must be
497      * read prior to getting the value of any other column. The next
498      * call to a getter method implicitly closes the stream.  Also, a
499      * stream may return <code>0</code> when the method
500      * <code>InputStream.available</code>
501      * is called whether there is data available or not.
502      *
503      * @param columnIndex the first column is 1, the second is 2, ...
504      * @return a Java input stream that delivers the database column value
505      *         as a stream of uninterpreted bytes;
506      *         if the value is SQL <code>NULL</code>, the value returned is
507      *         <code>null</code>
508      * @exception SQLException if the columnIndex is not valid;
509      * if a database access error occurs or this method is
510      *            called on a closed result set
511      */
getBinaryStream(int columnIndex)512     java.io.InputStream getBinaryStream(int columnIndex)
513         throws SQLException;
514 
515 
516     // Methods for accessing results by column label
517 
518     /**
519      * Retrieves the value of the designated column in the current row
520      * of this <code>ResultSet</code> object as
521      * a <code>String</code> in the Java programming language.
522      *
523      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
524      * @return the column value; if the value is SQL <code>NULL</code>, the
525      * value returned is <code>null</code>
526      * @exception SQLException if the columnLabel is not valid;
527      * if a database access error occurs or this method is
528      *            called on a closed result set
529      */
getString(String columnLabel)530     String getString(String columnLabel) throws SQLException;
531 
532     /**
533      * Retrieves the value of the designated column in the current row
534      * of this <code>ResultSet</code> object as
535      * a <code>boolean</code> in the Java programming language.
536      *
537      * <P>If the designated column has a datatype of CHAR or VARCHAR
538      * and contains a "0" or has a datatype of BIT, TINYINT, SMALLINT, INTEGER or BIGINT
539      * and contains  a 0, a value of <code>false</code> is returned.  If the designated column has a datatype
540      * of CHAR or VARCHAR
541      * and contains a "1" or has a datatype of BIT, TINYINT, SMALLINT, INTEGER or BIGINT
542      * and contains  a 1, a value of <code>true</code> is returned.
543      *
544      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
545      * @return the column value; if the value is SQL <code>NULL</code>, the
546      * value returned is <code>false</code>
547      * @exception SQLException if the columnLabel is not valid;
548      * if a database access error occurs or this method is
549      *            called on a closed result set
550      */
getBoolean(String columnLabel)551     boolean getBoolean(String columnLabel) throws SQLException;
552 
553     /**
554      * Retrieves the value of the designated column in the current row
555      * of this <code>ResultSet</code> object as
556      * a <code>byte</code> in the Java programming language.
557      *
558      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
559      * @return the column value; if the value is SQL <code>NULL</code>, the
560      * value returned is <code>0</code>
561      * @exception SQLException if the columnLabel is not valid;
562      * if a database access error occurs or this method is
563      *            called on a closed result set
564      */
getByte(String columnLabel)565     byte getByte(String columnLabel) throws SQLException;
566 
567     /**
568      * Retrieves the value of the designated column in the current row
569      * of this <code>ResultSet</code> object as
570      * a <code>short</code> in the Java programming language.
571      *
572      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
573      * @return the column value; if the value is SQL <code>NULL</code>, the
574      * value returned is <code>0</code>
575      * @exception SQLException if the columnLabel is not valid;
576      * if a database access error occurs or this method is
577      *            called on a closed result set
578      */
getShort(String columnLabel)579     short getShort(String columnLabel) throws SQLException;
580 
581     /**
582      * Retrieves the value of the designated column in the current row
583      * of this <code>ResultSet</code> object as
584      * an <code>int</code> in the Java programming language.
585      *
586      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
587      * @return the column value; if the value is SQL <code>NULL</code>, the
588      * value returned is <code>0</code>
589      * @exception SQLException if the columnLabel is not valid;
590      * if a database access error occurs or this method is
591      *            called on a closed result set
592      */
getInt(String columnLabel)593     int getInt(String columnLabel) throws SQLException;
594 
595     /**
596      * Retrieves the value of the designated column in the current row
597      * of this <code>ResultSet</code> object as
598      * a <code>long</code> in the Java programming language.
599      *
600      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
601      * @return the column value; if the value is SQL <code>NULL</code>, the
602      * value returned is <code>0</code>
603      * @exception SQLException if the columnLabel is not valid;
604      * if a database access error occurs or this method is
605      *            called on a closed result set
606      */
getLong(String columnLabel)607     long getLong(String columnLabel) throws SQLException;
608 
609     /**
610      * Retrieves the value of the designated column in the current row
611      * of this <code>ResultSet</code> object as
612      * a <code>float</code> in the Java programming language.
613      *
614      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
615      * @return the column value; if the value is SQL <code>NULL</code>, the
616      * value returned is <code>0</code>
617      * @exception SQLException if the columnLabel is not valid;
618      * if a database access error occurs or this method is
619      *            called on a closed result set
620      */
getFloat(String columnLabel)621     float getFloat(String columnLabel) throws SQLException;
622 
623     /**
624      * Retrieves the value of the designated column in the current row
625      * of this <code>ResultSet</code> object as
626      * a <code>double</code> in the Java programming language.
627      *
628      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
629      * @return the column value; if the value is SQL <code>NULL</code>, the
630      * value returned is <code>0</code>
631      * @exception SQLException if the columnLabel is not valid;
632      * if a database access error occurs or this method is
633      *            called on a closed result set
634      */
getDouble(String columnLabel)635     double getDouble(String columnLabel) throws SQLException;
636 
637     // Android-changed: Added reason to @deprecated to improve the documentation.
638     /**
639      * Retrieves the value of the designated column in the current row
640      * of this <code>ResultSet</code> object as
641      * a <code>java.math.BigDecimal</code> in the Java programming language.
642      *
643      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
644      * @param scale the number of digits to the right of the decimal point
645      * @return the column value; if the value is SQL <code>NULL</code>, the
646      * value returned is <code>null</code>
647      * @exception SQLException if the columnLabel is not valid;
648      * if a database access error occurs or this method is
649      *            called on a closed result set
650      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
651      * this method
652      * @deprecated Use {@code getBigDecimal(int columnIndex)}
653      *             or {@code getBigDecimal(String columnLabel)}
654      */
655     // Android-added: @Deprecated annotation from OpenJDK8u121-b13 to fix build warnings.
656     @Deprecated
getBigDecimal(String columnLabel, int scale)657     BigDecimal getBigDecimal(String columnLabel, int scale) throws SQLException;
658 
659     /**
660      * Retrieves the value of the designated column in the current row
661      * of this <code>ResultSet</code> object as
662      * a <code>byte</code> array in the Java programming language.
663      * The bytes represent the raw values returned by the driver.
664      *
665      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
666      * @return the column value; if the value is SQL <code>NULL</code>, the
667      * value returned is <code>null</code>
668      * @exception SQLException if the columnLabel is not valid;
669      * if a database access error occurs or this method is
670      *            called on a closed result set
671      */
getBytes(String columnLabel)672     byte[] getBytes(String columnLabel) throws SQLException;
673 
674     /**
675      * Retrieves the value of the designated column in the current row
676      * of this <code>ResultSet</code> object as
677      * a <code>java.sql.Date</code> object in the Java programming language.
678      *
679      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
680      * @return the column value; if the value is SQL <code>NULL</code>, the
681      * value returned is <code>null</code>
682      * @exception SQLException if the columnLabel is not valid;
683      * if a database access error occurs or this method is
684      *            called on a closed result set
685      */
getDate(String columnLabel)686     java.sql.Date getDate(String columnLabel) throws SQLException;
687 
688     /**
689      * Retrieves the value of the designated column in the current row
690      * of this <code>ResultSet</code> object as
691      * a <code>java.sql.Time</code> object in the Java programming language.
692      *
693      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
694      * @return the column value;
695      * if the value is SQL <code>NULL</code>,
696      * the value returned is <code>null</code>
697      * @exception SQLException if the columnLabel is not valid;
698      * if a database access error occurs or this method is
699      *            called on a closed result set
700      */
getTime(String columnLabel)701     java.sql.Time getTime(String columnLabel) throws SQLException;
702 
703     /**
704      * Retrieves the value of the designated column in the current row
705      * of this <code>ResultSet</code> object as
706      * a <code>java.sql.Timestamp</code> object in the Java programming language.
707      *
708      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
709      * @return the column value; if the value is SQL <code>NULL</code>, the
710      * value returned is <code>null</code>
711      * @exception SQLException if the columnLabel is not valid;
712      * if a database access error occurs or this method is
713      *            called on a closed result set
714      */
getTimestamp(String columnLabel)715     java.sql.Timestamp getTimestamp(String columnLabel) throws SQLException;
716 
717     /**
718      * Retrieves the value of the designated column in the current row
719      * of this <code>ResultSet</code> object as a stream of
720      * ASCII characters. The value can then be read in chunks from the
721      * stream. This method is particularly
722      * suitable for retrieving large <code>LONGVARCHAR</code> values.
723      * The JDBC driver will
724      * do any necessary conversion from the database format into ASCII.
725      *
726      * <P><B>Note:</B> All the data in the returned stream must be
727      * read prior to getting the value of any other column. The next
728      * call to a getter method implicitly closes the stream. Also, a
729      * stream may return <code>0</code> when the method <code>available</code>
730      * is called whether there is data available or not.
731      *
732      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
733      * @return a Java input stream that delivers the database column value
734      * as a stream of one-byte ASCII characters.
735      * If the value is SQL <code>NULL</code>,
736      * the value returned is <code>null</code>.
737      * @exception SQLException if the columnLabel is not valid;
738      * if a database access error occurs or this method is
739      *            called on a closed result set
740      */
getAsciiStream(String columnLabel)741     java.io.InputStream getAsciiStream(String columnLabel) throws SQLException;
742 
743     /**
744      * Retrieves the value of the designated column in the current row
745      * of this <code>ResultSet</code> object as a stream of two-byte
746      * Unicode characters. The first byte is the high byte; the second
747      * byte is the low byte.
748      *
749      * The value can then be read in chunks from the
750      * stream. This method is particularly
751      * suitable for retrieving large <code>LONGVARCHAR</code> values.
752      * The JDBC technology-enabled driver will
753      * do any necessary conversion from the database format into Unicode.
754      *
755      * <P><B>Note:</B> All the data in the returned stream must be
756      * read prior to getting the value of any other column. The next
757      * call to a getter method implicitly closes the stream.
758      * Also, a stream may return <code>0</code> when the method
759      * <code>InputStream.available</code> is called, whether there
760      * is data available or not.
761      *
762      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
763      * @return a Java input stream that delivers the database column value
764      *         as a stream of two-byte Unicode characters.
765      *         If the value is SQL <code>NULL</code>, the value returned
766      *         is <code>null</code>.
767      * @exception SQLException if the columnLabel is not valid;
768      * if a database access error occurs or this method is
769      *            called on a closed result set
770      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
771      * this method
772      * @deprecated use <code>getCharacterStream</code> instead
773      */
774     // Android-added: @Deprecated annotation from OpenJDK8u121-b13 to fix build warnings.
775     @Deprecated
getUnicodeStream(String columnLabel)776     java.io.InputStream getUnicodeStream(String columnLabel) throws SQLException;
777 
778     /**
779      * Retrieves the value of the designated column in the current row
780      * of this <code>ResultSet</code> object as a stream of uninterpreted
781      * <code>byte</code>s.
782      * The value can then be read in chunks from the
783      * stream. This method is particularly
784      * suitable for retrieving large <code>LONGVARBINARY</code>
785      * values.
786      *
787      * <P><B>Note:</B> All the data in the returned stream must be
788      * read prior to getting the value of any other column. The next
789      * call to a getter method implicitly closes the stream. Also, a
790      * stream may return <code>0</code> when the method <code>available</code>
791      * is called whether there is data available or not.
792      *
793      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
794      * @return a Java input stream that delivers the database column value
795      * as a stream of uninterpreted bytes;
796      * if the value is SQL <code>NULL</code>, the result is <code>null</code>
797      * @exception SQLException if the columnLabel is not valid;
798      * if a database access error occurs or this method is
799      *            called on a closed result set
800      */
getBinaryStream(String columnLabel)801     java.io.InputStream getBinaryStream(String columnLabel)
802         throws SQLException;
803 
804 
805     // Advanced features:
806 
807     /**
808      * Retrieves the first warning reported by calls on this
809      * <code>ResultSet</code> object.
810      * Subsequent warnings on this <code>ResultSet</code> object
811      * will be chained to the <code>SQLWarning</code> object that
812      * this method returns.
813      *
814      * <P>The warning chain is automatically cleared each time a new
815      * row is read.  This method may not be called on a <code>ResultSet</code>
816      * object that has been closed; doing so will cause an
817      * <code>SQLException</code> to be thrown.
818      * <P>
819      * <B>Note:</B> This warning chain only covers warnings caused
820      * by <code>ResultSet</code> methods.  Any warning caused by
821      * <code>Statement</code> methods
822      * (such as reading OUT parameters) will be chained on the
823      * <code>Statement</code> object.
824      *
825      * @return the first <code>SQLWarning</code> object reported or
826      *         <code>null</code> if there are none
827      * @exception SQLException if a database access error occurs or this method is
828      *            called on a closed result set
829      */
getWarnings()830     SQLWarning getWarnings() throws SQLException;
831 
832     /**
833      * Clears all warnings reported on this <code>ResultSet</code> object.
834      * After this method is called, the method <code>getWarnings</code>
835      * returns <code>null</code> until a new warning is
836      * reported for this <code>ResultSet</code> object.
837      *
838      * @exception SQLException if a database access error occurs or this method is
839      *            called on a closed result set
840      */
clearWarnings()841     void clearWarnings() throws SQLException;
842 
843     /**
844      * Retrieves the name of the SQL cursor used by this <code>ResultSet</code>
845      * object.
846      *
847      * <P>In SQL, a result table is retrieved through a cursor that is
848      * named. The current row of a result set can be updated or deleted
849      * using a positioned update/delete statement that references the
850      * cursor name. To insure that the cursor has the proper isolation
851      * level to support update, the cursor's <code>SELECT</code> statement
852      * should be of the form <code>SELECT FOR UPDATE</code>. If
853      * <code>FOR UPDATE</code> is omitted, the positioned updates may fail.
854      *
855      * <P>The JDBC API supports this SQL feature by providing the name of the
856      * SQL cursor used by a <code>ResultSet</code> object.
857      * The current row of a <code>ResultSet</code> object
858      * is also the current row of this SQL cursor.
859      *
860      * @return the SQL name for this <code>ResultSet</code> object's cursor
861      * @exception SQLException if a database access error occurs or this method is called on a closed result set
862      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
863      * this method
864      */
getCursorName()865     String getCursorName() throws SQLException;
866 
867     /**
868      * Retrieves the  number, types and properties of
869      * this <code>ResultSet</code> object's columns.
870      *
871      * @return the description of this <code>ResultSet</code> object's columns
872      * @exception SQLException if a database access error occurs or this method is
873      *            called on a closed result set
874      */
getMetaData()875     ResultSetMetaData getMetaData() throws SQLException;
876 
877     /**
878      * <p>Gets the value of the designated column in the current row
879      * of this <code>ResultSet</code> object as
880      * an <code>Object</code> in the Java programming language.
881      *
882      * <p>This method will return the value of the given column as a
883      * Java object.  The type of the Java object will be the default
884      * Java object type corresponding to the column's SQL type,
885      * following the mapping for built-in types specified in the JDBC
886      * specification. If the value is an SQL <code>NULL</code>,
887      * the driver returns a Java <code>null</code>.
888      *
889      * <p>This method may also be used to read database-specific
890      * abstract data types.
891      *
892      * In the JDBC 2.0 API, the behavior of method
893      * <code>getObject</code> is extended to materialize
894      * data of SQL user-defined types.
895      * <p>
896      * If <code>Connection.getTypeMap</code> does not throw a
897      * <code>SQLFeatureNotSupportedException</code>,
898      * then when a column contains a structured or distinct value,
899      * the behavior of this method is as
900      * if it were a call to: <code>getObject(columnIndex,
901      * this.getStatement().getConnection().getTypeMap())</code>.
902      *
903      * If <code>Connection.getTypeMap</code> does throw a
904      * <code>SQLFeatureNotSupportedException</code>,
905      * then structured values are not supported, and distinct values
906      * are mapped to the default Java class as determined by the
907      * underlying SQL type of the DISTINCT type.
908      *
909      * @param columnIndex the first column is 1, the second is 2, ...
910      * @return a <code>java.lang.Object</code> holding the column value
911      * @exception SQLException if the columnIndex is not valid;
912      * if a database access error occurs or this method is
913      *            called on a closed result set
914      */
getObject(int columnIndex)915     Object getObject(int columnIndex) throws SQLException;
916 
917     /**
918      * <p>Gets the value of the designated column in the current row
919      * of this <code>ResultSet</code> object as
920      * an <code>Object</code> in the Java programming language.
921      *
922      * <p>This method will return the value of the given column as a
923      * Java object.  The type of the Java object will be the default
924      * Java object type corresponding to the column's SQL type,
925      * following the mapping for built-in types specified in the JDBC
926      * specification. If the value is an SQL <code>NULL</code>,
927      * the driver returns a Java <code>null</code>.
928      * <P>
929      * This method may also be used to read database-specific
930      * abstract data types.
931      * <P>
932      * In the JDBC 2.0 API, the behavior of the method
933      * <code>getObject</code> is extended to materialize
934      * data of SQL user-defined types.  When a column contains
935      * a structured or distinct value, the behavior of this method is as
936      * if it were a call to: <code>getObject(columnIndex,
937      * this.getStatement().getConnection().getTypeMap())</code>.
938      *
939      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
940      * @return a <code>java.lang.Object</code> holding the column value
941      * @exception SQLException if the columnLabel is not valid;
942      * if a database access error occurs or this method is
943      *            called on a closed result set
944      */
getObject(String columnLabel)945     Object getObject(String columnLabel) throws SQLException;
946 
947     //----------------------------------------------------------------
948 
949     /**
950      * Maps the given <code>ResultSet</code> column label to its
951      * <code>ResultSet</code> column index.
952      *
953      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
954      * @return the column index of the given column name
955      * @exception SQLException if the <code>ResultSet</code> object
956      * does not contain a column labeled <code>columnLabel</code>, a database access error occurs
957      *  or this method is called on a closed result set
958      */
findColumn(String columnLabel)959     int findColumn(String columnLabel) throws SQLException;
960 
961 
962     //--------------------------JDBC 2.0-----------------------------------
963 
964     //---------------------------------------------------------------------
965     // Getters and Setters
966     //---------------------------------------------------------------------
967 
968     /**
969      * Retrieves the value of the designated column in the current row
970      * of this <code>ResultSet</code> object as a
971      * <code>java.io.Reader</code> object.
972      * @return a <code>java.io.Reader</code> object that contains the column
973      * value; if the value is SQL <code>NULL</code>, the value returned is
974      * <code>null</code> in the Java programming language.
975      * @param columnIndex the first column is 1, the second is 2, ...
976      * @exception SQLException if the columnIndex is not valid;
977      * if a database access error occurs or this method is
978      *            called on a closed result set
979      * @since 1.2
980      */
getCharacterStream(int columnIndex)981     java.io.Reader getCharacterStream(int columnIndex) throws SQLException;
982 
983     /**
984      * Retrieves the value of the designated column in the current row
985      * of this <code>ResultSet</code> object as a
986      * <code>java.io.Reader</code> object.
987      *
988      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
989      * @return a <code>java.io.Reader</code> object that contains the column
990      * value; if the value is SQL <code>NULL</code>, the value returned is
991      * <code>null</code> in the Java programming language
992      * @exception SQLException if the columnLabel is not valid;
993      * if a database access error occurs or this method is
994      *            called on a closed result set
995      * @since 1.2
996      */
getCharacterStream(String columnLabel)997     java.io.Reader getCharacterStream(String columnLabel) throws SQLException;
998 
999     /**
1000      * Retrieves the value of the designated column in the current row
1001      * of this <code>ResultSet</code> object as a
1002      * <code>java.math.BigDecimal</code> with full precision.
1003      *
1004      * @param columnIndex the first column is 1, the second is 2, ...
1005      * @return the column value (full precision);
1006      * if the value is SQL <code>NULL</code>, the value returned is
1007      * <code>null</code> in the Java programming language.
1008      * @exception SQLException if the columnIndex is not valid;
1009      * if a database access error occurs or this method is
1010      *            called on a closed result set
1011      * @since 1.2
1012      */
getBigDecimal(int columnIndex)1013     BigDecimal getBigDecimal(int columnIndex) throws SQLException;
1014 
1015     /**
1016      * Retrieves the value of the designated column in the current row
1017      * of this <code>ResultSet</code> object as a
1018      * <code>java.math.BigDecimal</code> with full precision.
1019      *
1020      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
1021      * @return the column value (full precision);
1022      * if the value is SQL <code>NULL</code>, the value returned is
1023      * <code>null</code> in the Java programming language.
1024      * @exception SQLException if the columnLabel is not valid;
1025      * if a database access error occurs or this method is
1026      *            called on a closed result set
1027      * @since 1.2
1028      *
1029      */
getBigDecimal(String columnLabel)1030     BigDecimal getBigDecimal(String columnLabel) throws SQLException;
1031 
1032     //---------------------------------------------------------------------
1033     // Traversal/Positioning
1034     //---------------------------------------------------------------------
1035 
1036     /**
1037      * Retrieves whether the cursor is before the first row in
1038      * this <code>ResultSet</code> object.
1039      * <p>
1040      * <strong>Note:</strong>Support for the <code>isBeforeFirst</code> method
1041      * is optional for <code>ResultSet</code>s with a result
1042      * set type of <code>TYPE_FORWARD_ONLY</code>
1043      *
1044      * @return <code>true</code> if the cursor is before the first row;
1045      * <code>false</code> if the cursor is at any other position or the
1046      * result set contains no rows
1047      * @exception SQLException if a database access error occurs or this method is
1048      *            called on a closed result set
1049      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1050      * this method
1051      * @since 1.2
1052      */
isBeforeFirst()1053     boolean isBeforeFirst() throws SQLException;
1054 
1055     /**
1056      * Retrieves whether the cursor is after the last row in
1057      * this <code>ResultSet</code> object.
1058      * <p>
1059      * <strong>Note:</strong>Support for the <code>isAfterLast</code> method
1060      * is optional for <code>ResultSet</code>s with a result
1061      * set type of <code>TYPE_FORWARD_ONLY</code>
1062      *
1063      * @return <code>true</code> if the cursor is after the last row;
1064      * <code>false</code> if the cursor is at any other position or the
1065      * result set contains no rows
1066      * @exception SQLException if a database access error occurs or this method is
1067      *            called on a closed result set
1068      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1069      * this method
1070      * @since 1.2
1071      */
isAfterLast()1072     boolean isAfterLast() throws SQLException;
1073 
1074     /**
1075      * Retrieves whether the cursor is on the first row of
1076      * this <code>ResultSet</code> object.
1077      * <p>
1078      * <strong>Note:</strong>Support for the <code>isFirst</code> method
1079      * is optional for <code>ResultSet</code>s with a result
1080      * set type of <code>TYPE_FORWARD_ONLY</code>
1081      *
1082      * @return <code>true</code> if the cursor is on the first row;
1083      * <code>false</code> otherwise
1084      * @exception SQLException if a database access error occurs or this method is
1085      *            called on a closed result set
1086      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1087      * this method
1088      * @since 1.2
1089      */
isFirst()1090     boolean isFirst() throws SQLException;
1091 
1092     /**
1093      * Retrieves whether the cursor is on the last row of
1094      * this <code>ResultSet</code> object.
1095      *  <strong>Note:</strong> Calling the method <code>isLast</code> may be expensive
1096      * because the JDBC driver
1097      * might need to fetch ahead one row in order to determine
1098      * whether the current row is the last row in the result set.
1099      * <p>
1100      * <strong>Note:</strong> Support for the <code>isLast</code> method
1101      * is optional for <code>ResultSet</code>s with a result
1102      * set type of <code>TYPE_FORWARD_ONLY</code>
1103      * @return <code>true</code> if the cursor is on the last row;
1104      * <code>false</code> otherwise
1105      * @exception SQLException if a database access error occurs or this method is
1106      *            called on a closed result set
1107      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1108      * this method
1109      * @since 1.2
1110      */
isLast()1111     boolean isLast() throws SQLException;
1112 
1113     /**
1114      * Moves the cursor to the front of
1115      * this <code>ResultSet</code> object, just before the
1116      * first row. This method has no effect if the result set contains no rows.
1117      *
1118      * @exception SQLException if a database access error
1119      * occurs; this method is called on a closed result set or the
1120      * result set type is <code>TYPE_FORWARD_ONLY</code>
1121      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1122      * this method
1123      * @since 1.2
1124      */
beforeFirst()1125     void beforeFirst() throws SQLException;
1126 
1127     /**
1128      * Moves the cursor to the end of
1129      * this <code>ResultSet</code> object, just after the
1130      * last row. This method has no effect if the result set contains no rows.
1131      * @exception SQLException if a database access error
1132      * occurs; this method is called on a closed result set
1133      * or the result set type is <code>TYPE_FORWARD_ONLY</code>
1134      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1135      * this method
1136      * @since 1.2
1137      */
afterLast()1138     void afterLast() throws SQLException;
1139 
1140     /**
1141      * Moves the cursor to the first row in
1142      * this <code>ResultSet</code> object.
1143      *
1144      * @return <code>true</code> if the cursor is on a valid row;
1145      * <code>false</code> if there are no rows in the result set
1146      * @exception SQLException if a database access error
1147      * occurs; this method is called on a closed result set
1148      * or the result set type is <code>TYPE_FORWARD_ONLY</code>
1149      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1150      * this method
1151      * @since 1.2
1152      */
first()1153     boolean first() throws SQLException;
1154 
1155     /**
1156      * Moves the cursor to the last row in
1157      * this <code>ResultSet</code> object.
1158      *
1159      * @return <code>true</code> if the cursor is on a valid row;
1160      * <code>false</code> if there are no rows in the result set
1161      * @exception SQLException if a database access error
1162      * occurs; this method is called on a closed result set
1163      * or the result set type is <code>TYPE_FORWARD_ONLY</code>
1164      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1165      * this method
1166      * @since 1.2
1167      */
last()1168     boolean last() throws SQLException;
1169 
1170     /**
1171      * Retrieves the current row number.  The first row is number 1, the
1172      * second number 2, and so on.
1173      * <p>
1174      * <strong>Note:</strong>Support for the <code>getRow</code> method
1175      * is optional for <code>ResultSet</code>s with a result
1176      * set type of <code>TYPE_FORWARD_ONLY</code>
1177      *
1178      * @return the current row number; <code>0</code> if there is no current row
1179      * @exception SQLException if a database access error occurs
1180      * or this method is called on a closed result set
1181      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1182      * this method
1183      * @since 1.2
1184      */
getRow()1185     int getRow() throws SQLException;
1186 
1187     /**
1188      * Moves the cursor to the given row number in
1189      * this <code>ResultSet</code> object.
1190      *
1191      * <p>If the row number is positive, the cursor moves to
1192      * the given row number with respect to the
1193      * beginning of the result set.  The first row is row 1, the second
1194      * is row 2, and so on.
1195      *
1196      * <p>If the given row number is negative, the cursor moves to
1197      * an absolute row position with respect to
1198      * the end of the result set.  For example, calling the method
1199      * <code>absolute(-1)</code> positions the
1200      * cursor on the last row; calling the method <code>absolute(-2)</code>
1201      * moves the cursor to the next-to-last row, and so on.
1202      *
1203      * <p>If the row number specified is zero, the cursor is moved to
1204      * before the first row.
1205      *
1206      * <p>An attempt to position the cursor beyond the first/last row in
1207      * the result set leaves the cursor before the first row or after
1208      * the last row.
1209      *
1210      * <p><B>Note:</B> Calling <code>absolute(1)</code> is the same
1211      * as calling <code>first()</code>. Calling <code>absolute(-1)</code>
1212      * is the same as calling <code>last()</code>.
1213      *
1214      * @param row the number of the row to which the cursor should move.
1215      *        A value of zero indicates that the cursor will be positioned
1216      *        before the first row; a positive number indicates the row number
1217      *        counting from the beginning of the result set; a negative number
1218      *        indicates the row number counting from the end of the result set
1219      * @return <code>true</code> if the cursor is moved to a position in this
1220      * <code>ResultSet</code> object;
1221      * <code>false</code> if the cursor is before the first row or after the
1222      * last row
1223      * @exception SQLException if a database access error
1224      * occurs; this method is called on a closed result set
1225      * or the result set type is <code>TYPE_FORWARD_ONLY</code>
1226      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1227      * this method
1228      * @since 1.2
1229      */
absolute( int row )1230     boolean absolute( int row ) throws SQLException;
1231 
1232     /**
1233      * Moves the cursor a relative number of rows, either positive or negative.
1234      * Attempting to move beyond the first/last row in the
1235      * result set positions the cursor before/after the
1236      * the first/last row. Calling <code>relative(0)</code> is valid, but does
1237      * not change the cursor position.
1238      *
1239      * <p>Note: Calling the method <code>relative(1)</code>
1240      * is identical to calling the method <code>next()</code> and
1241      * calling the method <code>relative(-1)</code> is identical
1242      * to calling the method <code>previous()</code>.
1243      *
1244      * @param rows an <code>int</code> specifying the number of rows to
1245      *        move from the current row; a positive number moves the cursor
1246      *        forward; a negative number moves the cursor backward
1247      * @return <code>true</code> if the cursor is on a row;
1248      *         <code>false</code> otherwise
1249      * @exception SQLException if a database access error occurs;  this method
1250      * is called on a closed result set or the result set type is
1251      *            <code>TYPE_FORWARD_ONLY</code>
1252      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1253      * this method
1254      * @since 1.2
1255      */
relative( int rows )1256     boolean relative( int rows ) throws SQLException;
1257 
1258     /**
1259      * Moves the cursor to the previous row in this
1260      * <code>ResultSet</code> object.
1261      *<p>
1262      * When a call to the <code>previous</code> method returns <code>false</code>,
1263      * the cursor is positioned before the first row.  Any invocation of a
1264      * <code>ResultSet</code> method which requires a current row will result in a
1265      * <code>SQLException</code> being thrown.
1266      *<p>
1267      * If an input stream is open for the current row, a call to the method
1268      * <code>previous</code> will implicitly close it.  A <code>ResultSet</code>
1269      *  object's warning change is cleared when a new row is read.
1270      *<p>
1271      *
1272      * @return <code>true</code> if the cursor is now positioned on a valid row;
1273      * <code>false</code> if the cursor is positioned before the first row
1274      * @exception SQLException if a database access error
1275      * occurs; this method is called on a closed result set
1276      * or the result set type is <code>TYPE_FORWARD_ONLY</code>
1277      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1278      * this method
1279      * @since 1.2
1280      */
previous()1281     boolean previous() throws SQLException;
1282 
1283     //---------------------------------------------------------------------
1284     // Properties
1285     //---------------------------------------------------------------------
1286 
1287     /**
1288      * The constant indicating that the rows in a result set will be
1289      * processed in a forward direction; first-to-last.
1290      * This constant is used by the method <code>setFetchDirection</code>
1291      * as a hint to the driver, which the driver may ignore.
1292      * @since 1.2
1293      */
1294     int FETCH_FORWARD = 1000;
1295 
1296     /**
1297      * The constant indicating that the rows in a result set will be
1298      * processed in a reverse direction; last-to-first.
1299      * This constant is used by the method <code>setFetchDirection</code>
1300      * as a hint to the driver, which the driver may ignore.
1301      * @since 1.2
1302      */
1303     int FETCH_REVERSE = 1001;
1304 
1305     /**
1306      * The constant indicating that the order in which rows in a
1307      * result set will be processed is unknown.
1308      * This constant is used by the method <code>setFetchDirection</code>
1309      * as a hint to the driver, which the driver may ignore.
1310      */
1311     int FETCH_UNKNOWN = 1002;
1312 
1313     /**
1314      * Gives a hint as to the direction in which the rows in this
1315      * <code>ResultSet</code> object will be processed.
1316      * The initial value is determined by the
1317      * <code>Statement</code> object
1318      * that produced this <code>ResultSet</code> object.
1319      * The fetch direction may be changed at any time.
1320      *
1321      * @param direction an <code>int</code> specifying the suggested
1322      *        fetch direction; one of <code>ResultSet.FETCH_FORWARD</code>,
1323      *        <code>ResultSet.FETCH_REVERSE</code>, or
1324      *        <code>ResultSet.FETCH_UNKNOWN</code>
1325      * @exception SQLException if a database access error occurs; this
1326      * method is called on a closed result set or
1327      * the result set type is <code>TYPE_FORWARD_ONLY</code> and the fetch
1328      * direction is not <code>FETCH_FORWARD</code>
1329      * @since 1.2
1330      * @see Statement#setFetchDirection
1331      * @see #getFetchDirection
1332      */
setFetchDirection(int direction)1333     void setFetchDirection(int direction) throws SQLException;
1334 
1335     /**
1336      * Retrieves the fetch direction for this
1337      * <code>ResultSet</code> object.
1338      *
1339      * @return the current fetch direction for this <code>ResultSet</code> object
1340      * @exception SQLException if a database access error occurs
1341      * or this method is called on a closed result set
1342      * @since 1.2
1343      * @see #setFetchDirection
1344      */
getFetchDirection()1345     int getFetchDirection() throws SQLException;
1346 
1347     /**
1348      * Gives the JDBC driver a hint as to the number of rows that should
1349      * be fetched from the database when more rows are needed for this
1350      * <code>ResultSet</code> object.
1351      * If the fetch size specified is zero, the JDBC driver
1352      * ignores the value and is free to make its own best guess as to what
1353      * the fetch size should be.  The default value is set by the
1354      * <code>Statement</code> object
1355      * that created the result set.  The fetch size may be changed at any time.
1356      *
1357      * @param rows the number of rows to fetch
1358      * @exception SQLException if a database access error occurs; this method
1359      * is called on a closed result set or the
1360      * condition <code>rows >= 0 </code> is not satisfied
1361      * @since 1.2
1362      * @see #getFetchSize
1363      */
setFetchSize(int rows)1364     void setFetchSize(int rows) throws SQLException;
1365 
1366     /**
1367      * Retrieves the fetch size for this
1368      * <code>ResultSet</code> object.
1369      *
1370      * @return the current fetch size for this <code>ResultSet</code> object
1371      * @exception SQLException if a database access error occurs
1372      * or this method is called on a closed result set
1373      * @since 1.2
1374      * @see #setFetchSize
1375      */
getFetchSize()1376     int getFetchSize() throws SQLException;
1377 
1378     /**
1379      * The constant indicating the type for a <code>ResultSet</code> object
1380      * whose cursor may move only forward.
1381      * @since 1.2
1382      */
1383     int TYPE_FORWARD_ONLY = 1003;
1384 
1385     /**
1386      * The constant indicating the type for a <code>ResultSet</code> object
1387      * that is scrollable but generally not sensitive to changes to the data
1388      * that underlies the <code>ResultSet</code>.
1389      * @since 1.2
1390      */
1391     int TYPE_SCROLL_INSENSITIVE = 1004;
1392 
1393     /**
1394      * The constant indicating the type for a <code>ResultSet</code> object
1395      * that is scrollable and generally sensitive to changes to the data
1396      * that underlies the <code>ResultSet</code>.
1397      * @since 1.2
1398      */
1399     int TYPE_SCROLL_SENSITIVE = 1005;
1400 
1401     /**
1402      * Retrieves the type of this <code>ResultSet</code> object.
1403      * The type is determined by the <code>Statement</code> object
1404      * that created the result set.
1405      *
1406      * @return <code>ResultSet.TYPE_FORWARD_ONLY</code>,
1407      *         <code>ResultSet.TYPE_SCROLL_INSENSITIVE</code>,
1408      *         or <code>ResultSet.TYPE_SCROLL_SENSITIVE</code>
1409      * @exception SQLException if a database access error occurs
1410      * or this method is called on a closed result set
1411      * @since 1.2
1412      */
getType()1413     int getType() throws SQLException;
1414 
1415     /**
1416      * The constant indicating the concurrency mode for a
1417      * <code>ResultSet</code> object that may NOT be updated.
1418      * @since 1.2
1419      */
1420     int CONCUR_READ_ONLY = 1007;
1421 
1422     /**
1423      * The constant indicating the concurrency mode for a
1424      * <code>ResultSet</code> object that may be updated.
1425      * @since 1.2
1426      */
1427     int CONCUR_UPDATABLE = 1008;
1428 
1429     /**
1430      * Retrieves the concurrency mode of this <code>ResultSet</code> object.
1431      * The concurrency used is determined by the
1432      * <code>Statement</code> object that created the result set.
1433      *
1434      * @return the concurrency type, either
1435      *         <code>ResultSet.CONCUR_READ_ONLY</code>
1436      *         or <code>ResultSet.CONCUR_UPDATABLE</code>
1437      * @exception SQLException if a database access error occurs
1438      * or this method is called on a closed result set
1439      * @since 1.2
1440      */
getConcurrency()1441     int getConcurrency() throws SQLException;
1442 
1443     //---------------------------------------------------------------------
1444     // Updates
1445     //---------------------------------------------------------------------
1446 
1447     /**
1448      * Retrieves whether the current row has been updated.  The value returned
1449      * depends on whether or not the result set can detect updates.
1450      * <p>
1451      * <strong>Note:</strong> Support for the <code>rowUpdated</code> method is optional with a result set
1452      * concurrency of <code>CONCUR_READ_ONLY</code>
1453      * @return <code>true</code> if the current row is detected to
1454      * have been visibly updated by the owner or another; <code>false</code> otherwise
1455      * @exception SQLException if a database access error occurs
1456      * or this method is called on a closed result set
1457      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1458      * this method
1459      * @see DatabaseMetaData#updatesAreDetected
1460      * @since 1.2
1461      */
rowUpdated()1462     boolean rowUpdated() throws SQLException;
1463 
1464     /**
1465      * Retrieves whether the current row has had an insertion.
1466      * The value returned depends on whether or not this
1467      * <code>ResultSet</code> object can detect visible inserts.
1468      * <p>
1469      * <strong>Note:</strong> Support for the <code>rowInserted</code> method is optional with a result set
1470      * concurrency of <code>CONCUR_READ_ONLY</code>
1471      * @return <code>true</code> if the current row is detected to
1472      * have been inserted; <code>false</code> otherwise
1473      * @exception SQLException if a database access error occurs
1474      * or this method is called on a closed result set
1475      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1476      * this method
1477      *
1478      * @see DatabaseMetaData#insertsAreDetected
1479      * @since 1.2
1480      */
rowInserted()1481     boolean rowInserted() throws SQLException;
1482 
1483     /**
1484      * Retrieves whether a row has been deleted.  A deleted row may leave
1485      * a visible "hole" in a result set.  This method can be used to
1486      * detect holes in a result set.  The value returned depends on whether
1487      * or not this <code>ResultSet</code> object can detect deletions.
1488      * <p>
1489      * <strong>Note:</strong> Support for the <code>rowDeleted</code> method is optional with a result set
1490      * concurrency of <code>CONCUR_READ_ONLY</code>
1491      * @return <code>true</code> if the current row is detected to
1492      * have been deleted by the owner or another; <code>false</code> otherwise
1493      * @exception SQLException if a database access error occurs
1494      * or this method is called on a closed result set
1495      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1496      * this method
1497      *
1498      * @see DatabaseMetaData#deletesAreDetected
1499      * @since 1.2
1500      */
rowDeleted()1501     boolean rowDeleted() throws SQLException;
1502 
1503     /**
1504      * Updates the designated column with a <code>null</code> value.
1505      *
1506      * The updater methods are used to update column values in the
1507      * current row or the insert row.  The updater methods do not
1508      * update the underlying database; instead the <code>updateRow</code>
1509      * or <code>insertRow</code> methods are called to update the database.
1510      *
1511      * @param columnIndex the first column is 1, the second is 2, ...
1512      * @exception SQLException if the columnIndex is not valid;
1513      * if a database access error occurs;
1514      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1515      * or this method is called on a closed result set
1516      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1517      * this method
1518      * @since 1.2
1519      */
updateNull(int columnIndex)1520     void updateNull(int columnIndex) throws SQLException;
1521 
1522     /**
1523      * Updates the designated column with a <code>boolean</code> value.
1524      * The updater methods are used to update column values in the
1525      * current row or the insert row.  The updater methods do not
1526      * update the underlying database; instead the <code>updateRow</code> or
1527      * <code>insertRow</code> methods are called to update the database.
1528      *
1529      * @param columnIndex the first column is 1, the second is 2, ...
1530      * @param x the new column value
1531      * @exception SQLException if the columnIndex is not valid;
1532      * if a database access error occurs;
1533      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1534      * or this method is called on a closed result set
1535      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1536      * this method
1537      * @since 1.2
1538      */
updateBoolean(int columnIndex, boolean x)1539     void updateBoolean(int columnIndex, boolean x) throws SQLException;
1540 
1541     /**
1542      * Updates the designated column with a <code>byte</code> value.
1543      * The updater methods are used to update column values in the
1544      * current row or the insert row.  The updater methods do not
1545      * update the underlying database; instead the <code>updateRow</code> or
1546      * <code>insertRow</code> methods are called to update the database.
1547      *
1548      *
1549      * @param columnIndex the first column is 1, the second is 2, ...
1550      * @param x the new column value
1551      * @exception SQLException if the columnIndex is not valid;
1552      * if a database access error occurs;
1553      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1554      * or this method is called on a closed result set
1555      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1556      * this method
1557      * @since 1.2
1558      */
updateByte(int columnIndex, byte x)1559     void updateByte(int columnIndex, byte x) throws SQLException;
1560 
1561     /**
1562      * Updates the designated column with a <code>short</code> value.
1563      * The updater methods are used to update column values in the
1564      * current row or the insert row.  The updater methods do not
1565      * update the underlying database; instead the <code>updateRow</code> or
1566      * <code>insertRow</code> methods are called to update the database.
1567      *
1568      * @param columnIndex the first column is 1, the second is 2, ...
1569      * @param x the new column value
1570      * @exception SQLException if the columnIndex is not valid;
1571      * if a database access error occurs;
1572      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1573      * or this method is called on a closed result set
1574      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1575      * this method
1576      * @since 1.2
1577      */
updateShort(int columnIndex, short x)1578     void updateShort(int columnIndex, short x) throws SQLException;
1579 
1580     /**
1581      * Updates the designated column with an <code>int</code> value.
1582      * The updater methods are used to update column values in the
1583      * current row or the insert row.  The updater methods do not
1584      * update the underlying database; instead the <code>updateRow</code> or
1585      * <code>insertRow</code> methods are called to update the database.
1586      *
1587      * @param columnIndex the first column is 1, the second is 2, ...
1588      * @param x the new column value
1589      * @exception SQLException if the columnIndex is not valid;
1590      * if a database access error occurs;
1591      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1592      * or this method is called on a closed result set
1593      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1594      * this method
1595      * @since 1.2
1596      */
updateInt(int columnIndex, int x)1597     void updateInt(int columnIndex, int x) throws SQLException;
1598 
1599     /**
1600      * Updates the designated column with a <code>long</code> value.
1601      * The updater methods are used to update column values in the
1602      * current row or the insert row.  The updater methods do not
1603      * update the underlying database; instead the <code>updateRow</code> or
1604      * <code>insertRow</code> methods are called to update the database.
1605      *
1606      * @param columnIndex the first column is 1, the second is 2, ...
1607      * @param x the new column value
1608      * @exception SQLException if the columnIndex is not valid;
1609      * if a database access error occurs;
1610      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1611      * or this method is called on a closed result set
1612      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1613      * this method
1614      * @since 1.2
1615      */
updateLong(int columnIndex, long x)1616     void updateLong(int columnIndex, long x) throws SQLException;
1617 
1618     /**
1619      * Updates the designated column with a <code>float</code> value.
1620      * The updater methods are used to update column values in the
1621      * current row or the insert row.  The updater methods do not
1622      * update the underlying database; instead the <code>updateRow</code> or
1623      * <code>insertRow</code> methods are called to update the database.
1624      *
1625      * @param columnIndex the first column is 1, the second is 2, ...
1626      * @param x the new column value
1627      * @exception SQLException if the columnIndex is not valid;
1628      * if a database access error occurs;
1629      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1630      * or this method is called on a closed result set
1631      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1632      * this method
1633      * @since 1.2
1634      */
updateFloat(int columnIndex, float x)1635     void updateFloat(int columnIndex, float x) throws SQLException;
1636 
1637     /**
1638      * Updates the designated column with a <code>double</code> value.
1639      * The updater methods are used to update column values in the
1640      * current row or the insert row.  The updater methods do not
1641      * update the underlying database; instead the <code>updateRow</code> or
1642      * <code>insertRow</code> methods are called to update the database.
1643      *
1644      * @param columnIndex the first column is 1, the second is 2, ...
1645      * @param x the new column value
1646      * @exception SQLException if the columnIndex is not valid;
1647      * if a database access error occurs;
1648      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1649      * or this method is called on a closed result set
1650      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1651      * this method
1652      * @since 1.2
1653      */
updateDouble(int columnIndex, double x)1654     void updateDouble(int columnIndex, double x) throws SQLException;
1655 
1656     /**
1657      * Updates the designated column with a <code>java.math.BigDecimal</code>
1658      * value.
1659      * The updater methods are used to update column values in the
1660      * current row or the insert row.  The updater methods do not
1661      * update the underlying database; instead the <code>updateRow</code> or
1662      * <code>insertRow</code> methods are called to update the database.
1663      *
1664      * @param columnIndex the first column is 1, the second is 2, ...
1665      * @param x the new column value
1666      * @exception SQLException if the columnIndex is not valid;
1667      * if a database access error occurs;
1668      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1669      * or this method is called on a closed result set
1670      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1671      * this method
1672      * @since 1.2
1673      */
updateBigDecimal(int columnIndex, BigDecimal x)1674     void updateBigDecimal(int columnIndex, BigDecimal x) throws SQLException;
1675 
1676     /**
1677      * Updates the designated column with a <code>String</code> value.
1678      * The updater methods are used to update column values in the
1679      * current row or the insert row.  The updater methods do not
1680      * update the underlying database; instead the <code>updateRow</code> or
1681      * <code>insertRow</code> methods are called to update the database.
1682      *
1683      * @param columnIndex the first column is 1, the second is 2, ...
1684      * @param x the new column value
1685      * @exception SQLException if the columnIndex is not valid;
1686      * if a database access error occurs;
1687      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1688      * or this method is called on a closed result set
1689      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1690      * this method
1691      * @since 1.2
1692      */
updateString(int columnIndex, String x)1693     void updateString(int columnIndex, String x) throws SQLException;
1694 
1695     /**
1696      * Updates the designated column with a <code>byte</code> array value.
1697      * The updater methods are used to update column values in the
1698      * current row or the insert row.  The updater methods do not
1699      * update the underlying database; instead the <code>updateRow</code> or
1700      * <code>insertRow</code> methods are called to update the database.
1701      *
1702      * @param columnIndex the first column is 1, the second is 2, ...
1703      * @param x the new column value
1704      * @exception SQLException if the columnIndex is not valid;
1705      * if a database access error occurs;
1706      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1707      * or this method is called on a closed result set
1708      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1709      * this method
1710      * @since 1.2
1711      */
updateBytes(int columnIndex, byte x[])1712     void updateBytes(int columnIndex, byte x[]) throws SQLException;
1713 
1714     /**
1715      * Updates the designated column with a <code>java.sql.Date</code> value.
1716      * The updater methods are used to update column values in the
1717      * current row or the insert row.  The updater methods do not
1718      * update the underlying database; instead the <code>updateRow</code> or
1719      * <code>insertRow</code> methods are called to update the database.
1720      *
1721      * @param columnIndex the first column is 1, the second is 2, ...
1722      * @param x the new column value
1723      * @exception SQLException if the columnIndex is not valid;
1724      * if a database access error occurs;
1725      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1726      * or this method is called on a closed result set
1727      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1728      * this method
1729      * @since 1.2
1730      */
updateDate(int columnIndex, java.sql.Date x)1731     void updateDate(int columnIndex, java.sql.Date x) throws SQLException;
1732 
1733     /**
1734      * Updates the designated column with a <code>java.sql.Time</code> value.
1735      * The updater methods are used to update column values in the
1736      * current row or the insert row.  The updater methods do not
1737      * update the underlying database; instead the <code>updateRow</code> or
1738      * <code>insertRow</code> methods are called to update the database.
1739      *
1740      * @param columnIndex the first column is 1, the second is 2, ...
1741      * @param x the new column value
1742      * @exception SQLException if the columnIndex is not valid;
1743      * if a database access error occurs;
1744      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1745      * or this method is called on a closed result set
1746      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1747      * this method
1748      * @since 1.2
1749      */
updateTime(int columnIndex, java.sql.Time x)1750     void updateTime(int columnIndex, java.sql.Time x) throws SQLException;
1751 
1752     /**
1753      * Updates the designated column with a <code>java.sql.Timestamp</code>
1754      * value.
1755      * The updater methods are used to update column values in the
1756      * current row or the insert row.  The updater methods do not
1757      * update the underlying database; instead the <code>updateRow</code> or
1758      * <code>insertRow</code> methods are called to update the database.
1759      *
1760      * @param columnIndex the first column is 1, the second is 2, ...
1761      * @param x the new column value
1762      * @exception SQLException if the columnIndex is not valid;
1763      * if a database access error occurs;
1764      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1765      * or this method is called on a closed result set
1766      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1767      * this method
1768      * @since 1.2
1769      */
updateTimestamp(int columnIndex, java.sql.Timestamp x)1770     void updateTimestamp(int columnIndex, java.sql.Timestamp x)
1771       throws SQLException;
1772 
1773     /**
1774      * Updates the designated column with an ascii stream value, which will have
1775      * the specified number of bytes.
1776      * The updater methods are used to update column values in the
1777      * current row or the insert row.  The updater methods do not
1778      * update the underlying database; instead the <code>updateRow</code> or
1779      * <code>insertRow</code> methods are called to update the database.
1780      *
1781      * @param columnIndex the first column is 1, the second is 2, ...
1782      * @param x the new column value
1783      * @param length the length of the stream
1784      * @exception SQLException if the columnIndex is not valid;
1785      * if a database access error occurs;
1786      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1787      * or this method is called on a closed result set
1788      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1789      * this method
1790      * @since 1.2
1791      */
updateAsciiStream(int columnIndex, java.io.InputStream x, int length)1792     void updateAsciiStream(int columnIndex,
1793                            java.io.InputStream x,
1794                            int length) throws SQLException;
1795 
1796     /**
1797      * Updates the designated column with a binary stream value, which will have
1798      * the specified number of bytes.
1799      * The updater methods are used to update column values in the
1800      * current row or the insert row.  The updater methods do not
1801      * update the underlying database; instead the <code>updateRow</code> or
1802      * <code>insertRow</code> methods are called to update the database.
1803      *
1804      * @param columnIndex the first column is 1, the second is 2, ...
1805      * @param x the new column value
1806      * @param length the length of the stream
1807      * @exception SQLException if the columnIndex is not valid;
1808      * if a database access error occurs;
1809      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1810      * or this method is called on a closed result set
1811      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1812      * this method
1813      * @since 1.2
1814      */
updateBinaryStream(int columnIndex, java.io.InputStream x, int length)1815     void updateBinaryStream(int columnIndex,
1816                             java.io.InputStream x,
1817                             int length) throws SQLException;
1818 
1819     /**
1820      * Updates the designated column with a character stream value, which will have
1821      * the specified number of bytes.
1822      * The updater methods are used to update column values in the
1823      * current row or the insert row.  The updater methods do not
1824      * update the underlying database; instead the <code>updateRow</code> or
1825      * <code>insertRow</code> methods are called to update the database.
1826      *
1827      * @param columnIndex the first column is 1, the second is 2, ...
1828      * @param x the new column value
1829      * @param length the length of the stream
1830      * @exception SQLException if the columnIndex is not valid;
1831      * if a database access error occurs;
1832      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1833      * or this method is called on a closed result set
1834      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1835      * this method
1836      * @since 1.2
1837      */
updateCharacterStream(int columnIndex, java.io.Reader x, int length)1838     void updateCharacterStream(int columnIndex,
1839                              java.io.Reader x,
1840                              int length) throws SQLException;
1841 
1842     /**
1843      * Updates the designated column with an <code>Object</code> value.
1844      * The updater methods are used to update column values in the
1845      * current row or the insert row.  The updater methods do not
1846      * update the underlying database; instead the <code>updateRow</code> or
1847      * <code>insertRow</code> methods are called to update the database.
1848      *<p>
1849      * If the second argument is an <code>InputStream</code> then the stream must contain
1850      * the number of bytes specified by scaleOrLength.  If the second argument is a
1851      * <code>Reader</code> then the reader must contain the number of characters specified
1852      * by scaleOrLength. If these conditions are not true the driver will generate a
1853      * <code>SQLException</code> when the statement is executed.
1854      *
1855      * @param columnIndex the first column is 1, the second is 2, ...
1856      * @param x the new column value
1857      * @param scaleOrLength for an object of <code>java.math.BigDecimal</code> ,
1858      *          this is the number of digits after the decimal point. For
1859      *          Java Object types <code>InputStream</code> and <code>Reader</code>,
1860      *          this is the length
1861      *          of the data in the stream or reader.  For all other types,
1862      *          this value will be ignored.
1863      * @exception SQLException if the columnIndex is not valid;
1864      * if a database access error occurs;
1865      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1866      * or this method is called on a closed result set
1867      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1868      * this method
1869      * @since 1.2
1870      */
updateObject(int columnIndex, Object x, int scaleOrLength)1871     void updateObject(int columnIndex, Object x, int scaleOrLength)
1872       throws SQLException;
1873 
1874     /**
1875      * Updates the designated column with an <code>Object</code> value.
1876      * The updater methods are used to update column values in the
1877      * current row or the insert row.  The updater methods do not
1878      * update the underlying database; instead the <code>updateRow</code> or
1879      * <code>insertRow</code> methods are called to update the database.
1880      *
1881      * @param columnIndex the first column is 1, the second is 2, ...
1882      * @param x the new column value
1883      * @exception SQLException if the columnIndex is not valid;
1884      * if a database access error occurs;
1885      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1886      * or this method is called on a closed result set
1887      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1888      * this method
1889      * @since 1.2
1890      */
updateObject(int columnIndex, Object x)1891     void updateObject(int columnIndex, Object x) throws SQLException;
1892 
1893     /**
1894      * Updates the designated column with a <code>null</code> value.
1895      * The updater methods are used to update column values in the
1896      * current row or the insert row.  The updater methods do not
1897      * update the underlying database; instead the <code>updateRow</code> or
1898      * <code>insertRow</code> methods are called to update the database.
1899      *
1900      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
1901      * @exception SQLException if the columnLabel is not valid;
1902      * if a database access error occurs;
1903      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1904      * or this method is called on a closed result set
1905      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1906      * this method
1907      * @since 1.2
1908      */
updateNull(String columnLabel)1909     void updateNull(String columnLabel) throws SQLException;
1910 
1911     /**
1912      * Updates the designated column with a <code>boolean</code> value.
1913      * The updater methods are used to update column values in the
1914      * current row or the insert row.  The updater methods do not
1915      * update the underlying database; instead the <code>updateRow</code> or
1916      * <code>insertRow</code> methods are called to update the database.
1917      *
1918      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
1919      * @param x the new column value
1920      * @exception SQLException if the columnLabel is not valid;
1921      * if a database access error occurs;
1922      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1923      * or this method is called on a closed result set
1924      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1925      * this method
1926      * @since 1.2
1927      */
updateBoolean(String columnLabel, boolean x)1928     void updateBoolean(String columnLabel, boolean x) throws SQLException;
1929 
1930     /**
1931      * Updates the designated column with a <code>byte</code> value.
1932      * The updater methods are used to update column values in the
1933      * current row or the insert row.  The updater methods do not
1934      * update the underlying database; instead the <code>updateRow</code> or
1935      * <code>insertRow</code> methods are called to update the database.
1936      *
1937      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
1938      * @param x the new column value
1939      * @exception SQLException if the columnLabel is not valid;
1940      * if a database access error occurs;
1941      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1942      * or this method is called on a closed result set
1943      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1944      * this method
1945      * @since 1.2
1946      */
updateByte(String columnLabel, byte x)1947     void updateByte(String columnLabel, byte x) throws SQLException;
1948 
1949     /**
1950      * Updates the designated column with a <code>short</code> value.
1951      * The updater methods are used to update column values in the
1952      * current row or the insert row.  The updater methods do not
1953      * update the underlying database; instead the <code>updateRow</code> or
1954      * <code>insertRow</code> methods are called to update the database.
1955      *
1956      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
1957      * @param x the new column value
1958      * @exception SQLException if the columnLabel is not valid;
1959      * if a database access error occurs;
1960      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1961      * or this method is called on a closed result set
1962      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1963      * this method
1964      * @since 1.2
1965      */
updateShort(String columnLabel, short x)1966     void updateShort(String columnLabel, short x) throws SQLException;
1967 
1968     /**
1969      * Updates the designated column with an <code>int</code> value.
1970      * The updater methods are used to update column values in the
1971      * current row or the insert row.  The updater methods do not
1972      * update the underlying database; instead the <code>updateRow</code> or
1973      * <code>insertRow</code> methods are called to update the database.
1974      *
1975      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
1976      * @param x the new column value
1977      * @exception SQLException if the columnLabel is not valid;
1978      * if a database access error occurs;
1979      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1980      * or this method is called on a closed result set
1981      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
1982      * this method
1983      * @since 1.2
1984      */
updateInt(String columnLabel, int x)1985     void updateInt(String columnLabel, int x) throws SQLException;
1986 
1987     /**
1988      * Updates the designated column with a <code>long</code> value.
1989      * The updater methods are used to update column values in the
1990      * current row or the insert row.  The updater methods do not
1991      * update the underlying database; instead the <code>updateRow</code> or
1992      * <code>insertRow</code> methods are called to update the database.
1993      *
1994      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
1995      * @param x the new column value
1996      * @exception SQLException if the columnLabel is not valid;
1997      * if a database access error occurs;
1998      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
1999      * or this method is called on a closed result set
2000      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2001      * this method
2002      * @since 1.2
2003      */
updateLong(String columnLabel, long x)2004     void updateLong(String columnLabel, long x) throws SQLException;
2005 
2006     /**
2007      * Updates the designated column with a <code>float </code> value.
2008      * The updater methods are used to update column values in the
2009      * current row or the insert row.  The updater methods do not
2010      * update the underlying database; instead the <code>updateRow</code> or
2011      * <code>insertRow</code> methods are called to update the database.
2012      *
2013      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2014      * @param x the new column value
2015      * @exception SQLException if the columnLabel is not valid;
2016      * if a database access error occurs;
2017      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2018      * or this method is called on a closed result set
2019      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2020      * this method
2021      * @since 1.2
2022      */
updateFloat(String columnLabel, float x)2023     void updateFloat(String columnLabel, float x) throws SQLException;
2024 
2025     /**
2026      * Updates the designated column with a <code>double</code> value.
2027      * The updater methods are used to update column values in the
2028      * current row or the insert row.  The updater methods do not
2029      * update the underlying database; instead the <code>updateRow</code> or
2030      * <code>insertRow</code> methods are called to update the database.
2031      *
2032      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2033      * @param x the new column value
2034      * @exception SQLException if the columnLabel is not valid;
2035      * if a database access error occurs;
2036      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2037      * or this method is called on a closed result set
2038      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2039      * this method
2040      * @since 1.2
2041      */
updateDouble(String columnLabel, double x)2042     void updateDouble(String columnLabel, double x) throws SQLException;
2043 
2044     /**
2045      * Updates the designated column with a <code>java.sql.BigDecimal</code>
2046      * value.
2047      * The updater methods are used to update column values in the
2048      * current row or the insert row.  The updater methods do not
2049      * update the underlying database; instead the <code>updateRow</code> or
2050      * <code>insertRow</code> methods are called to update the database.
2051      *
2052      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2053      * @param x the new column value
2054      * @exception SQLException if the columnLabel is not valid;
2055      * if a database access error occurs;
2056      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2057      * or this method is called on a closed result set
2058      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2059      * this method
2060      * @since 1.2
2061      */
updateBigDecimal(String columnLabel, BigDecimal x)2062     void updateBigDecimal(String columnLabel, BigDecimal x) throws SQLException;
2063 
2064     /**
2065      * Updates the designated column with a <code>String</code> value.
2066      * The updater methods are used to update column values in the
2067      * current row or the insert row.  The updater methods do not
2068      * update the underlying database; instead the <code>updateRow</code> or
2069      * <code>insertRow</code> methods are called to update the database.
2070      *
2071      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2072      * @param x the new column value
2073      * @exception SQLException if the columnLabel is not valid;
2074      * if a database access error occurs;
2075      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2076      * or this method is called on a closed result set
2077      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2078      * this method
2079      * @since 1.2
2080      */
updateString(String columnLabel, String x)2081     void updateString(String columnLabel, String x) throws SQLException;
2082 
2083     /**
2084      * Updates the designated column with a byte array value.
2085      *
2086      * The updater methods are used to update column values in the
2087      * current row or the insert row.  The updater methods do not
2088      * update the underlying database; instead the <code>updateRow</code>
2089      * or <code>insertRow</code> methods are called to update the database.
2090      *
2091      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2092      * @param x the new column value
2093      * @exception SQLException if the columnLabel is not valid;
2094      * if a database access error occurs;
2095      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2096      * or this method is called on a closed result set
2097      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2098      * this method
2099      * @since 1.2
2100      */
updateBytes(String columnLabel, byte x[])2101     void updateBytes(String columnLabel, byte x[]) throws SQLException;
2102 
2103     /**
2104      * Updates the designated column with a <code>java.sql.Date</code> value.
2105      * The updater methods are used to update column values in the
2106      * current row or the insert row.  The updater methods do not
2107      * update the underlying database; instead the <code>updateRow</code> or
2108      * <code>insertRow</code> methods are called to update the database.
2109      *
2110      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2111      * @param x the new column value
2112      * @exception SQLException if the columnLabel is not valid;
2113      * if a database access error occurs;
2114      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2115      * or this method is called on a closed result set
2116      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2117      * this method
2118      * @since 1.2
2119      */
updateDate(String columnLabel, java.sql.Date x)2120     void updateDate(String columnLabel, java.sql.Date x) throws SQLException;
2121 
2122     /**
2123      * Updates the designated column with a <code>java.sql.Time</code> value.
2124      * The updater methods are used to update column values in the
2125      * current row or the insert row.  The updater methods do not
2126      * update the underlying database; instead the <code>updateRow</code> or
2127      * <code>insertRow</code> methods are called to update the database.
2128      *
2129      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2130      * @param x the new column value
2131      * @exception SQLException if the columnLabel is not valid;
2132      * if a database access error occurs;
2133      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2134      * or this method is called on a closed result set
2135      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2136      * this method
2137      * @since 1.2
2138      */
updateTime(String columnLabel, java.sql.Time x)2139     void updateTime(String columnLabel, java.sql.Time x) throws SQLException;
2140 
2141     /**
2142      * Updates the designated column with a <code>java.sql.Timestamp</code>
2143      * value.
2144      * The updater methods are used to update column values in the
2145      * current row or the insert row.  The updater methods do not
2146      * update the underlying database; instead the <code>updateRow</code> or
2147      * <code>insertRow</code> methods are called to update the database.
2148      *
2149      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2150      * @param x the new column value
2151      * @exception SQLException if the columnLabel is not valid;
2152      * if a database access error occurs;
2153      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2154      * or this method is called on a closed result set
2155      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2156      * this method
2157      * @since 1.2
2158      */
updateTimestamp(String columnLabel, java.sql.Timestamp x)2159     void updateTimestamp(String columnLabel, java.sql.Timestamp x)
2160       throws SQLException;
2161 
2162     /**
2163      * Updates the designated column with an ascii stream value, which will have
2164      * the specified number of bytes.
2165      * The updater methods are used to update column values in the
2166      * current row or the insert row.  The updater methods do not
2167      * update the underlying database; instead the <code>updateRow</code> or
2168      * <code>insertRow</code> methods are called to update the database.
2169      *
2170      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2171      * @param x the new column value
2172      * @param length the length of the stream
2173      * @exception SQLException if the columnLabel is not valid;
2174      * if a database access error occurs;
2175      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2176      * or this method is called on a closed result set
2177      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2178      * this method
2179      * @since 1.2
2180      */
updateAsciiStream(String columnLabel, java.io.InputStream x, int length)2181     void updateAsciiStream(String columnLabel,
2182                            java.io.InputStream x,
2183                            int length) throws SQLException;
2184 
2185     /**
2186      * Updates the designated column with a binary stream value, which will have
2187      * the specified number of bytes.
2188      * The updater methods are used to update column values in the
2189      * current row or the insert row.  The updater methods do not
2190      * update the underlying database; instead the <code>updateRow</code> or
2191      * <code>insertRow</code> methods are called to update the database.
2192      *
2193      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2194      * @param x the new column value
2195      * @param length the length of the stream
2196      * @exception SQLException if the columnLabel is not valid;
2197      * if a database access error occurs;
2198      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2199      * or this method is called on a closed result set
2200      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2201      * this method
2202      * @since 1.2
2203      */
updateBinaryStream(String columnLabel, java.io.InputStream x, int length)2204     void updateBinaryStream(String columnLabel,
2205                             java.io.InputStream x,
2206                             int length) throws SQLException;
2207 
2208     /**
2209      * Updates the designated column with a character stream value, which will have
2210      * the specified number of bytes.
2211      * The updater methods are used to update column values in the
2212      * current row or the insert row.  The updater methods do not
2213      * update the underlying database; instead the <code>updateRow</code> or
2214      * <code>insertRow</code> methods are called to update the database.
2215      *
2216      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2217      * @param reader the <code>java.io.Reader</code> object containing
2218      *        the new column value
2219      * @param length the length of the stream
2220      * @exception SQLException if the columnLabel is not valid;
2221      * if a database access error occurs;
2222      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2223      * or this method is called on a closed result set
2224      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2225      * this method
2226      * @since 1.2
2227      */
updateCharacterStream(String columnLabel, java.io.Reader reader, int length)2228     void updateCharacterStream(String columnLabel,
2229                              java.io.Reader reader,
2230                              int length) throws SQLException;
2231 
2232     /**
2233      * Updates the designated column with an <code>Object</code> value.
2234      * The updater methods are used to update column values in the
2235      * current row or the insert row.  The updater methods do not
2236      * update the underlying database; instead the <code>updateRow</code> or
2237      * <code>insertRow</code> methods are called to update the database.
2238      *<p>
2239      * If the second argument is an <code>InputStream</code> then the stream must contain
2240      * the number of bytes specified by scaleOrLength.  If the second argument is a
2241      * <code>Reader</code> then the reader must contain the number of characters specified
2242      * by scaleOrLength. If these conditions are not true the driver will generate a
2243      * <code>SQLException</code> when the statement is executed.
2244      *
2245      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2246      * @param x the new column value
2247      * @param scaleOrLength for an object of <code>java.math.BigDecimal</code> ,
2248      *          this is the number of digits after the decimal point. For
2249      *          Java Object types <code>InputStream</code> and <code>Reader</code>,
2250      *          this is the length
2251      *          of the data in the stream or reader.  For all other types,
2252      *          this value will be ignored.
2253      * @exception SQLException if the columnLabel is not valid;
2254      * if a database access error occurs;
2255      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2256      * or this method is called on a closed result set
2257      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2258      * this method
2259      * @since 1.2
2260      */
updateObject(String columnLabel, Object x, int scaleOrLength)2261     void updateObject(String columnLabel, Object x, int scaleOrLength)
2262       throws SQLException;
2263 
2264     /**
2265      * Updates the designated column with an <code>Object</code> value.
2266      * The updater methods are used to update column values in the
2267      * current row or the insert row.  The updater methods do not
2268      * update the underlying database; instead the <code>updateRow</code> or
2269      * <code>insertRow</code> methods are called to update the database.
2270      *
2271      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2272      * @param x the new column value
2273      * @exception SQLException if the columnLabel is not valid;
2274      * if a database access error occurs;
2275      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2276      * or this method is called on a closed result set
2277      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2278      * this method
2279      * @since 1.2
2280      */
updateObject(String columnLabel, Object x)2281     void updateObject(String columnLabel, Object x) throws SQLException;
2282 
2283     /**
2284      * Inserts the contents of the insert row into this
2285      * <code>ResultSet</code> object and into the database.
2286      * The cursor must be on the insert row when this method is called.
2287      *
2288      * @exception SQLException if a database access error occurs;
2289      * the result set concurrency is <code>CONCUR_READ_ONLY</code>,
2290      * this method is called on a closed result set,
2291      * if this method is called when the cursor is not on the insert row,
2292      * or if not all of non-nullable columns in
2293      * the insert row have been given a non-null value
2294      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2295      * this method
2296      * @since 1.2
2297      */
insertRow()2298     void insertRow() throws SQLException;
2299 
2300     /**
2301      * Updates the underlying database with the new contents of the
2302      * current row of this <code>ResultSet</code> object.
2303      * This method cannot be called when the cursor is on the insert row.
2304      *
2305      * @exception SQLException if a database access error occurs;
2306      * the result set concurrency is <code>CONCUR_READ_ONLY</code>;
2307      *  this method is called on a closed result set or
2308      * if this method is called when the cursor is on the insert row
2309      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2310      * this method
2311      * @since 1.2
2312      */
updateRow()2313     void updateRow() throws SQLException;
2314 
2315     /**
2316      * Deletes the current row from this <code>ResultSet</code> object
2317      * and from the underlying database.  This method cannot be called when
2318      * the cursor is on the insert row.
2319      *
2320      * @exception SQLException if a database access error occurs;
2321      * the result set concurrency is <code>CONCUR_READ_ONLY</code>;
2322      * this method is called on a closed result set
2323      * or if this method is called when the cursor is on the insert row
2324      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2325      * this method
2326      * @since 1.2
2327      */
deleteRow()2328     void deleteRow() throws SQLException;
2329 
2330     /**
2331      * Refreshes the current row with its most recent value in
2332      * the database.  This method cannot be called when
2333      * the cursor is on the insert row.
2334      *
2335      * <P>The <code>refreshRow</code> method provides a way for an
2336      * application to
2337      * explicitly tell the JDBC driver to refetch a row(s) from the
2338      * database.  An application may want to call <code>refreshRow</code> when
2339      * caching or prefetching is being done by the JDBC driver to
2340      * fetch the latest value of a row from the database.  The JDBC driver
2341      * may actually refresh multiple rows at once if the fetch size is
2342      * greater than one.
2343      *
2344      * <P> All values are refetched subject to the transaction isolation
2345      * level and cursor sensitivity.  If <code>refreshRow</code> is called after
2346      * calling an updater method, but before calling
2347      * the method <code>updateRow</code>, then the
2348      * updates made to the row are lost.  Calling the method
2349      * <code>refreshRow</code> frequently will likely slow performance.
2350      *
2351      * @exception SQLException if a database access error
2352      * occurs; this method is called on a closed result set;
2353      * the result set type is <code>TYPE_FORWARD_ONLY</code> or if this
2354      * method is called when the cursor is on the insert row
2355      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2356      * this method or this method is not supported for the specified result
2357      * set type and result set concurrency.
2358      * @since 1.2
2359      */
refreshRow()2360     void refreshRow() throws SQLException;
2361 
2362     /**
2363      * Cancels the updates made to the current row in this
2364      * <code>ResultSet</code> object.
2365      * This method may be called after calling an
2366      * updater method(s) and before calling
2367      * the method <code>updateRow</code> to roll back
2368      * the updates made to a row.  If no updates have been made or
2369      * <code>updateRow</code> has already been called, this method has no
2370      * effect.
2371      *
2372      * @exception SQLException if a database access error
2373      *            occurs; this method is called on a closed result set;
2374      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2375      * or if this method is called when the cursor is
2376      *            on the insert row
2377       * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2378      * this method
2379      * @since 1.2
2380      */
cancelRowUpdates()2381     void cancelRowUpdates() throws SQLException;
2382 
2383     /**
2384      * Moves the cursor to the insert row.  The current cursor position is
2385      * remembered while the cursor is positioned on the insert row.
2386      *
2387      * The insert row is a special row associated with an updatable
2388      * result set.  It is essentially a buffer where a new row may
2389      * be constructed by calling the updater methods prior to
2390      * inserting the row into the result set.
2391      *
2392      * Only the updater, getter,
2393      * and <code>insertRow</code> methods may be
2394      * called when the cursor is on the insert row.  All of the columns in
2395      * a result set must be given a value each time this method is
2396      * called before calling <code>insertRow</code>.
2397      * An updater method must be called before a
2398      * getter method can be called on a column value.
2399      *
2400      * @exception SQLException if a database access error occurs; this
2401      * method is called on a closed result set
2402      * or the result set concurrency is <code>CONCUR_READ_ONLY</code>
2403      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2404      * this method
2405      * @since 1.2
2406      */
moveToInsertRow()2407     void moveToInsertRow() throws SQLException;
2408 
2409     /**
2410      * Moves the cursor to the remembered cursor position, usually the
2411      * current row.  This method has no effect if the cursor is not on
2412      * the insert row.
2413      *
2414      * @exception SQLException if a database access error occurs; this
2415      * method is called on a closed result set
2416      *  or the result set concurrency is <code>CONCUR_READ_ONLY</code>
2417      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2418      * this method
2419      * @since 1.2
2420      */
moveToCurrentRow()2421     void moveToCurrentRow() throws SQLException;
2422 
2423     /**
2424      * Retrieves the <code>Statement</code> object that produced this
2425      * <code>ResultSet</code> object.
2426      * If the result set was generated some other way, such as by a
2427      * <code>DatabaseMetaData</code> method, this method  may return
2428      * <code>null</code>.
2429      *
2430      * @return the <code>Statment</code> object that produced
2431      * this <code>ResultSet</code> object or <code>null</code>
2432      * if the result set was produced some other way
2433      * @exception SQLException if a database access error occurs
2434      * or this method is called on a closed result set
2435      * @since 1.2
2436      */
getStatement()2437     Statement getStatement() throws SQLException;
2438 
2439     /**
2440      * Retrieves the value of the designated column in the current row
2441      * of this <code>ResultSet</code> object as an <code>Object</code>
2442      * in the Java programming language.
2443      * If the value is an SQL <code>NULL</code>,
2444      * the driver returns a Java <code>null</code>.
2445      * This method uses the given <code>Map</code> object
2446      * for the custom mapping of the
2447      * SQL structured or distinct type that is being retrieved.
2448      *
2449      * @param columnIndex the first column is 1, the second is 2, ...
2450      * @param map a <code>java.util.Map</code> object that contains the mapping
2451      * from SQL type names to classes in the Java programming language
2452      * @return an <code>Object</code> in the Java programming language
2453      * representing the SQL value
2454      * @exception SQLException if the columnIndex is not valid;
2455      * if a database access error occurs
2456      * or this method is called on a closed result set
2457      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2458      * this method
2459      * @since 1.2
2460      */
getObject(int columnIndex, java.util.Map<String,Class<?>> map)2461     Object getObject(int columnIndex, java.util.Map<String,Class<?>> map)
2462         throws SQLException;
2463 
2464     /**
2465      * Retrieves the value of the designated column in the current row
2466      * of this <code>ResultSet</code> object as a <code>Ref</code> object
2467      * in the Java programming language.
2468      *
2469      * @param columnIndex the first column is 1, the second is 2, ...
2470      * @return a <code>Ref</code> object representing an SQL <code>REF</code>
2471      *         value
2472      * @exception SQLException if the columnIndex is not valid;
2473      * if a database access error occurs
2474      * or this method is called on a closed result set
2475      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2476      * this method
2477      * @since 1.2
2478      */
getRef(int columnIndex)2479     Ref getRef(int columnIndex) throws SQLException;
2480 
2481     /**
2482      * Retrieves the value of the designated column in the current row
2483      * of this <code>ResultSet</code> object as a <code>Blob</code> object
2484      * in the Java programming language.
2485      *
2486      * @param columnIndex the first column is 1, the second is 2, ...
2487      * @return a <code>Blob</code> object representing the SQL
2488      *         <code>BLOB</code> value in the specified column
2489      * @exception SQLException if the columnIndex is not valid;
2490      * if a database access error occurs
2491      * or this method is called on a closed result set
2492      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2493      * this method
2494      * @since 1.2
2495      */
getBlob(int columnIndex)2496     Blob getBlob(int columnIndex) throws SQLException;
2497 
2498     /**
2499      * Retrieves the value of the designated column in the current row
2500      * of this <code>ResultSet</code> object as a <code>Clob</code> object
2501      * in the Java programming language.
2502      *
2503      * @param columnIndex the first column is 1, the second is 2, ...
2504      * @return a <code>Clob</code> object representing the SQL
2505      *         <code>CLOB</code> value in the specified column
2506      * @exception SQLException if the columnIndex is not valid;
2507      * if a database access error occurs
2508      * or this method is called on a closed result set
2509      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2510      * this method
2511      * @since 1.2
2512      */
getClob(int columnIndex)2513     Clob getClob(int columnIndex) throws SQLException;
2514 
2515     /**
2516      * Retrieves the value of the designated column in the current row
2517      * of this <code>ResultSet</code> object as an <code>Array</code> object
2518      * in the Java programming language.
2519      *
2520      * @param columnIndex the first column is 1, the second is 2, ...
2521      * @return an <code>Array</code> object representing the SQL
2522      *         <code>ARRAY</code> value in the specified column
2523      * @exception SQLException if the columnIndex is not valid;
2524      * if a database access error occurs
2525      * or this method is called on a closed result set
2526       * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2527      * this method
2528      * @since 1.2
2529      */
getArray(int columnIndex)2530     Array getArray(int columnIndex) throws SQLException;
2531 
2532     /**
2533      * Retrieves the value of the designated column in the current row
2534      * of this <code>ResultSet</code> object as an <code>Object</code>
2535      * in the Java programming language.
2536      * If the value is an SQL <code>NULL</code>,
2537      * the driver returns a Java <code>null</code>.
2538      * This method uses the specified <code>Map</code> object for
2539      * custom mapping if appropriate.
2540      *
2541      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2542      * @param map a <code>java.util.Map</code> object that contains the mapping
2543      * from SQL type names to classes in the Java programming language
2544      * @return an <code>Object</code> representing the SQL value in the
2545      *         specified column
2546      * @exception SQLException if the columnLabel is not valid;
2547      * if a database access error occurs
2548      * or this method is called on a closed result set
2549      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2550      * this method
2551      * @since 1.2
2552      */
getObject(String columnLabel, java.util.Map<String,Class<?>> map)2553     Object getObject(String columnLabel, java.util.Map<String,Class<?>> map)
2554       throws SQLException;
2555 
2556     /**
2557      * Retrieves the value of the designated column in the current row
2558      * of this <code>ResultSet</code> object as a <code>Ref</code> object
2559      * in the Java programming language.
2560      *
2561      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2562      * @return a <code>Ref</code> object representing the SQL <code>REF</code>
2563      *         value in the specified column
2564      * @exception SQLException if the columnLabel is not valid;
2565      * if a database access error occurs
2566      * or this method is called on a closed result set
2567       * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2568      * this method
2569      * @since 1.2
2570      */
getRef(String columnLabel)2571     Ref getRef(String columnLabel) throws SQLException;
2572 
2573     /**
2574      * Retrieves the value of the designated column in the current row
2575      * of this <code>ResultSet</code> object as a <code>Blob</code> object
2576      * in the Java programming language.
2577      *
2578      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2579      * @return a <code>Blob</code> object representing the SQL <code>BLOB</code>
2580      *         value in the specified column
2581      * @exception SQLException if the columnLabel is not valid;
2582      * if a database access error occurs
2583      * or this method is called on a closed result set
2584      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2585      * this method
2586      * @since 1.2
2587      */
getBlob(String columnLabel)2588     Blob getBlob(String columnLabel) throws SQLException;
2589 
2590     /**
2591      * Retrieves the value of the designated column in the current row
2592      * of this <code>ResultSet</code> object as a <code>Clob</code> object
2593      * in the Java programming language.
2594      *
2595      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2596      * @return a <code>Clob</code> object representing the SQL <code>CLOB</code>
2597      * value in the specified column
2598      * @exception SQLException if the columnLabel is not valid;
2599      * if a database access error occurs
2600      * or this method is called on a closed result set
2601       * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2602      * this method
2603      * @since 1.2
2604      */
getClob(String columnLabel)2605     Clob getClob(String columnLabel) throws SQLException;
2606 
2607     /**
2608      * Retrieves the value of the designated column in the current row
2609      * of this <code>ResultSet</code> object as an <code>Array</code> object
2610      * in the Java programming language.
2611      *
2612      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2613      * @return an <code>Array</code> object representing the SQL <code>ARRAY</code> value in
2614      *         the specified column
2615      * @exception SQLException if the columnLabel is not valid;
2616      * if a database access error occurs
2617      * or this method is called on a closed result set
2618      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2619      * this method
2620      * @since 1.2
2621      */
getArray(String columnLabel)2622     Array getArray(String columnLabel) throws SQLException;
2623 
2624     /**
2625      * Retrieves the value of the designated column in the current row
2626      * of this <code>ResultSet</code> object as a <code>java.sql.Date</code> object
2627      * in the Java programming language.
2628      * This method uses the given calendar to construct an appropriate millisecond
2629      * value for the date if the underlying database does not store
2630      * timezone information.
2631      *
2632      * @param columnIndex the first column is 1, the second is 2, ...
2633      * @param cal the <code>java.util.Calendar</code> object
2634      * to use in constructing the date
2635      * @return the column value as a <code>java.sql.Date</code> object;
2636      * if the value is SQL <code>NULL</code>,
2637      * the value returned is <code>null</code> in the Java programming language
2638      * @exception SQLException if the columnIndex is not valid;
2639      * if a database access error occurs
2640      * or this method is called on a closed result set
2641      * @since 1.2
2642      */
getDate(int columnIndex, Calendar cal)2643     java.sql.Date getDate(int columnIndex, Calendar cal) throws SQLException;
2644 
2645     /**
2646      * Retrieves the value of the designated column in the current row
2647      * of this <code>ResultSet</code> object as a <code>java.sql.Date</code> object
2648      * in the Java programming language.
2649      * This method uses the given calendar to construct an appropriate millisecond
2650      * value for the date if the underlying database does not store
2651      * timezone information.
2652      *
2653      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2654      * @param cal the <code>java.util.Calendar</code> object
2655      * to use in constructing the date
2656      * @return the column value as a <code>java.sql.Date</code> object;
2657      * if the value is SQL <code>NULL</code>,
2658      * the value returned is <code>null</code> in the Java programming language
2659      * @exception SQLException if the columnLabel is not valid;
2660      * if a database access error occurs
2661      * or this method is called on a closed result set
2662      * @since 1.2
2663      */
getDate(String columnLabel, Calendar cal)2664     java.sql.Date getDate(String columnLabel, Calendar cal) throws SQLException;
2665 
2666     /**
2667      * Retrieves the value of the designated column in the current row
2668      * of this <code>ResultSet</code> object as a <code>java.sql.Time</code> object
2669      * in the Java programming language.
2670      * This method uses the given calendar to construct an appropriate millisecond
2671      * value for the time if the underlying database does not store
2672      * timezone information.
2673      *
2674      * @param columnIndex the first column is 1, the second is 2, ...
2675      * @param cal the <code>java.util.Calendar</code> object
2676      * to use in constructing the time
2677      * @return the column value as a <code>java.sql.Time</code> object;
2678      * if the value is SQL <code>NULL</code>,
2679      * the value returned is <code>null</code> in the Java programming language
2680      * @exception SQLException if the columnIndex is not valid;
2681      * if a database access error occurs
2682      * or this method is called on a closed result set
2683      * @since 1.2
2684      */
getTime(int columnIndex, Calendar cal)2685     java.sql.Time getTime(int columnIndex, Calendar cal) throws SQLException;
2686 
2687     /**
2688      * Retrieves the value of the designated column in the current row
2689      * of this <code>ResultSet</code> object as a <code>java.sql.Time</code> object
2690      * in the Java programming language.
2691      * This method uses the given calendar to construct an appropriate millisecond
2692      * value for the time if the underlying database does not store
2693      * timezone information.
2694      *
2695      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2696      * @param cal the <code>java.util.Calendar</code> object
2697      * to use in constructing the time
2698      * @return the column value as a <code>java.sql.Time</code> object;
2699      * if the value is SQL <code>NULL</code>,
2700      * the value returned is <code>null</code> in the Java programming language
2701      * @exception SQLException if the columnLabel is not valid;
2702      * if a database access error occurs
2703      * or this method is called on a closed result set
2704      * @since 1.2
2705      */
getTime(String columnLabel, Calendar cal)2706     java.sql.Time getTime(String columnLabel, Calendar cal) throws SQLException;
2707 
2708     /**
2709      * Retrieves the value of the designated column in the current row
2710      * of this <code>ResultSet</code> object as a <code>java.sql.Timestamp</code> object
2711      * in the Java programming language.
2712      * This method uses the given calendar to construct an appropriate millisecond
2713      * value for the timestamp if the underlying database does not store
2714      * timezone information.
2715      *
2716      * @param columnIndex the first column is 1, the second is 2, ...
2717      * @param cal the <code>java.util.Calendar</code> object
2718      * to use in constructing the timestamp
2719      * @return the column value as a <code>java.sql.Timestamp</code> object;
2720      * if the value is SQL <code>NULL</code>,
2721      * the value returned is <code>null</code> in the Java programming language
2722      * @exception SQLException if the columnIndex is not valid;
2723      * if a database access error occurs
2724      * or this method is called on a closed result set
2725      * @since 1.2
2726      */
getTimestamp(int columnIndex, Calendar cal)2727     java.sql.Timestamp getTimestamp(int columnIndex, Calendar cal)
2728       throws SQLException;
2729 
2730     /**
2731      * Retrieves the value of the designated column in the current row
2732      * of this <code>ResultSet</code> object as a <code>java.sql.Timestamp</code> object
2733      * in the Java programming language.
2734      * This method uses the given calendar to construct an appropriate millisecond
2735      * value for the timestamp if the underlying database does not store
2736      * timezone information.
2737      *
2738      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2739      * @param cal the <code>java.util.Calendar</code> object
2740      * to use in constructing the date
2741      * @return the column value as a <code>java.sql.Timestamp</code> object;
2742      * if the value is SQL <code>NULL</code>,
2743      * the value returned is <code>null</code> in the Java programming language
2744      * @exception SQLException if the columnLabel is not valid or
2745      * if a database access error occurs
2746      * or this method is called on a closed result set
2747      * @since 1.2
2748      */
getTimestamp(String columnLabel, Calendar cal)2749     java.sql.Timestamp getTimestamp(String columnLabel, Calendar cal)
2750       throws SQLException;
2751 
2752     //-------------------------- JDBC 3.0 ----------------------------------------
2753 
2754     /**
2755      * The constant indicating that open <code>ResultSet</code> objects with this
2756      * holdability will remain open when the current transaction is commited.
2757      *
2758      * @since 1.4
2759      */
2760     int HOLD_CURSORS_OVER_COMMIT = 1;
2761 
2762     /**
2763      * The constant indicating that open <code>ResultSet</code> objects with this
2764      * holdability will be closed when the current transaction is commited.
2765      *
2766      * @since 1.4
2767      */
2768     int CLOSE_CURSORS_AT_COMMIT = 2;
2769 
2770     /**
2771      * Retrieves the value of the designated column in the current row
2772      * of this <code>ResultSet</code> object as a <code>java.net.URL</code>
2773      * object in the Java programming language.
2774      *
2775      * @param columnIndex the index of the column 1 is the first, 2 is the second,...
2776      * @return the column value as a <code>java.net.URL</code> object;
2777      * if the value is SQL <code>NULL</code>,
2778      * the value returned is <code>null</code> in the Java programming language
2779      * @exception SQLException if the columnIndex is not valid;
2780      * if a database access error occurs; this method
2781      * is called on a closed result set or if a URL is malformed
2782       * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2783      * this method
2784      * @since 1.4
2785      */
getURL(int columnIndex)2786     java.net.URL getURL(int columnIndex) throws SQLException;
2787 
2788     /**
2789      * Retrieves the value of the designated column in the current row
2790      * of this <code>ResultSet</code> object as a <code>java.net.URL</code>
2791      * object in the Java programming language.
2792      *
2793      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2794      * @return the column value as a <code>java.net.URL</code> object;
2795      * if the value is SQL <code>NULL</code>,
2796      * the value returned is <code>null</code> in the Java programming language
2797      * @exception SQLException if the columnLabel is not valid;
2798      * if a database access error occurs; this method
2799      * is called on a closed result set or if a URL is malformed
2800      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2801      * this method
2802      * @since 1.4
2803      */
getURL(String columnLabel)2804     java.net.URL getURL(String columnLabel) throws SQLException;
2805 
2806     /**
2807      * Updates the designated column with a <code>java.sql.Ref</code> value.
2808      * The updater methods are used to update column values in the
2809      * current row or the insert row.  The updater methods do not
2810      * update the underlying database; instead the <code>updateRow</code> or
2811      * <code>insertRow</code> methods are called to update the database.
2812      *
2813      * @param columnIndex the first column is 1, the second is 2, ...
2814      * @param x the new column value
2815      * @exception SQLException if the columnIndex is not valid;
2816      * if a database access error occurs;
2817      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2818      * or this method is called on a closed result set
2819      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2820      * this method
2821      * @since 1.4
2822      */
updateRef(int columnIndex, java.sql.Ref x)2823     void updateRef(int columnIndex, java.sql.Ref x) throws SQLException;
2824 
2825     /**
2826      * Updates the designated column with a <code>java.sql.Ref</code> value.
2827      * The updater methods are used to update column values in the
2828      * current row or the insert row.  The updater methods do not
2829      * update the underlying database; instead the <code>updateRow</code> or
2830      * <code>insertRow</code> methods are called to update the database.
2831      *
2832      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2833      * @param x the new column value
2834      * @exception SQLException if the columnLabel is not valid;
2835      * if a database access error occurs;
2836      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2837      * or this method is called on a closed result set
2838      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2839      * this method
2840      * @since 1.4
2841      */
updateRef(String columnLabel, java.sql.Ref x)2842     void updateRef(String columnLabel, java.sql.Ref x) throws SQLException;
2843 
2844     /**
2845      * Updates the designated column with a <code>java.sql.Blob</code> value.
2846      * The updater methods are used to update column values in the
2847      * current row or the insert row.  The updater methods do not
2848      * update the underlying database; instead the <code>updateRow</code> or
2849      * <code>insertRow</code> methods are called to update the database.
2850      *
2851      * @param columnIndex the first column is 1, the second is 2, ...
2852      * @param x the new column value
2853      * @exception SQLException if the columnIndex is not valid;
2854      * if a database access error occurs;
2855      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2856      * or this method is called on a closed result set
2857      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2858      * this method
2859      * @since 1.4
2860      */
updateBlob(int columnIndex, java.sql.Blob x)2861     void updateBlob(int columnIndex, java.sql.Blob x) throws SQLException;
2862 
2863     /**
2864      * Updates the designated column with a <code>java.sql.Blob</code> value.
2865      * The updater methods are used to update column values in the
2866      * current row or the insert row.  The updater methods do not
2867      * update the underlying database; instead the <code>updateRow</code> or
2868      * <code>insertRow</code> methods are called to update the database.
2869      *
2870      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2871      * @param x the new column value
2872      * @exception SQLException if the columnLabel is not valid;
2873      * if a database access error occurs;
2874      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2875      * or this method is called on a closed result set
2876      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2877      * this method
2878      * @since 1.4
2879      */
updateBlob(String columnLabel, java.sql.Blob x)2880     void updateBlob(String columnLabel, java.sql.Blob x) throws SQLException;
2881 
2882     /**
2883      * Updates the designated column with a <code>java.sql.Clob</code> value.
2884      * The updater methods are used to update column values in the
2885      * current row or the insert row.  The updater methods do not
2886      * update the underlying database; instead the <code>updateRow</code> or
2887      * <code>insertRow</code> methods are called to update the database.
2888      *
2889      * @param columnIndex the first column is 1, the second is 2, ...
2890      * @param x the new column value
2891      * @exception SQLException if the columnIndex is not valid;
2892      * if a database access error occurs;
2893      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2894      * or this method is called on a closed result set
2895      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2896      * this method
2897      * @since 1.4
2898      */
updateClob(int columnIndex, java.sql.Clob x)2899     void updateClob(int columnIndex, java.sql.Clob x) throws SQLException;
2900 
2901     /**
2902      * Updates the designated column with a <code>java.sql.Clob</code> value.
2903      * The updater methods are used to update column values in the
2904      * current row or the insert row.  The updater methods do not
2905      * update the underlying database; instead the <code>updateRow</code> or
2906      * <code>insertRow</code> methods are called to update the database.
2907      *
2908      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2909      * @param x the new column value
2910      * @exception SQLException if the columnLabel is not valid;
2911      * if a database access error occurs;
2912      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2913      * or this method is called on a closed result set
2914      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2915      * this method
2916      * @since 1.4
2917      */
updateClob(String columnLabel, java.sql.Clob x)2918     void updateClob(String columnLabel, java.sql.Clob x) throws SQLException;
2919 
2920     /**
2921      * Updates the designated column with a <code>java.sql.Array</code> value.
2922      * The updater methods are used to update column values in the
2923      * current row or the insert row.  The updater methods do not
2924      * update the underlying database; instead the <code>updateRow</code> or
2925      * <code>insertRow</code> methods are called to update the database.
2926      *
2927      * @param columnIndex the first column is 1, the second is 2, ...
2928      * @param x the new column value
2929      * @exception SQLException if the columnIndex is not valid;
2930      * if a database access error occurs;
2931      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2932      * or this method is called on a closed result set
2933      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2934      * this method
2935      * @since 1.4
2936      */
updateArray(int columnIndex, java.sql.Array x)2937     void updateArray(int columnIndex, java.sql.Array x) throws SQLException;
2938 
2939     /**
2940      * Updates the designated column with a <code>java.sql.Array</code> value.
2941      * The updater methods are used to update column values in the
2942      * current row or the insert row.  The updater methods do not
2943      * update the underlying database; instead the <code>updateRow</code> or
2944      * <code>insertRow</code> methods are called to update the database.
2945      *
2946      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2947      * @param x the new column value
2948      * @exception SQLException if the columnLabel is not valid;
2949      * if a database access error occurs;
2950      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
2951      * or this method is called on a closed result set
2952      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2953      * this method
2954      * @since 1.4
2955      */
updateArray(String columnLabel, java.sql.Array x)2956     void updateArray(String columnLabel, java.sql.Array x) throws SQLException;
2957 
2958     //------------------------- JDBC 4.0 -----------------------------------
2959 
2960     /**
2961      * Retrieves the value of the designated column in the current row of this
2962      * <code>ResultSet</code> object as a <code>java.sql.RowId</code> object in the Java
2963      * programming language.
2964      *
2965      * @param columnIndex the first column is 1, the second 2, ...
2966      * @return the column value; if the value is a SQL <code>NULL</code> the
2967      *     value returned is <code>null</code>
2968      * @throws SQLException if the columnIndex is not valid;
2969      * if a database access error occurs
2970      * or this method is called on a closed result set
2971      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2972      * this method
2973      * @since 1.6
2974      */
getRowId(int columnIndex)2975     RowId getRowId(int columnIndex) throws SQLException;
2976 
2977     /**
2978      * Retrieves the value of the designated column in the current row of this
2979      * <code>ResultSet</code> object as a <code>java.sql.RowId</code> object in the Java
2980      * programming language.
2981      *
2982      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
2983      * @return the column value ; if the value is a SQL <code>NULL</code> the
2984      *     value returned is <code>null</code>
2985      * @throws SQLException if the columnLabel is not valid;
2986      * if a database access error occurs
2987      * or this method is called on a closed result set
2988      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
2989      * this method
2990      * @since 1.6
2991      */
getRowId(String columnLabel)2992     RowId getRowId(String columnLabel) throws SQLException;
2993 
2994     /**
2995      * Updates the designated column with a <code>RowId</code> value. The updater
2996      * methods are used to update column values in the current row or the insert
2997      * row. The updater methods do not update the underlying database; instead
2998      * the <code>updateRow</code> or <code>insertRow</code> methods are called
2999      * to update the database.
3000      *
3001      * @param columnIndex the first column is 1, the second 2, ...
3002      * @param x the column value
3003      * @exception SQLException if the columnIndex is not valid;
3004      * if a database access error occurs;
3005      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3006      * or this method is called on a closed result set
3007      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3008      * this method
3009      * @since 1.6
3010      */
updateRowId(int columnIndex, RowId x)3011     void updateRowId(int columnIndex, RowId x) throws SQLException;
3012 
3013     /**
3014      * Updates the designated column with a <code>RowId</code> value. The updater
3015      * methods are used to update column values in the current row or the insert
3016      * row. The updater methods do not update the underlying database; instead
3017      * the <code>updateRow</code> or <code>insertRow</code> methods are called
3018      * to update the database.
3019      *
3020      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3021      * @param x the column value
3022      * @exception SQLException if the columnLabel is not valid;
3023      * if a database access error occurs;
3024      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3025      * or this method is called on a closed result set
3026      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3027      * this method
3028      * @since 1.6
3029      */
updateRowId(String columnLabel, RowId x)3030     void updateRowId(String columnLabel, RowId x) throws SQLException;
3031 
3032     /**
3033      * Retrieves the holdability of this <code>ResultSet</code> object
3034      * @return  either <code>ResultSet.HOLD_CURSORS_OVER_COMMIT</code> or <code>ResultSet.CLOSE_CURSORS_AT_COMMIT</code>
3035      * @throws SQLException if a database access error occurs
3036      * or this method is called on a closed result set
3037      * @since 1.6
3038      */
getHoldability()3039     int getHoldability() throws SQLException;
3040 
3041     /**
3042      * Retrieves whether this <code>ResultSet</code> object has been closed. A <code>ResultSet</code> is closed if the
3043      * method close has been called on it, or if it is automatically closed.
3044      *
3045      * @return true if this <code>ResultSet</code> object is closed; false if it is still open
3046      * @throws SQLException if a database access error occurs
3047      * @since 1.6
3048      */
isClosed()3049     boolean isClosed() throws SQLException;
3050 
3051     /**
3052      * Updates the designated column with a <code>String</code> value.
3053      * It is intended for use when updating <code>NCHAR</code>,<code>NVARCHAR</code>
3054      * and <code>LONGNVARCHAR</code> columns.
3055      * The updater methods are used to update column values in the
3056      * current row or the insert row.  The updater methods do not
3057      * update the underlying database; instead the <code>updateRow</code> or
3058      * <code>insertRow</code> methods are called to update the database.
3059      *
3060      * @param columnIndex the first column is 1, the second 2, ...
3061      * @param nString the value for the column to be updated
3062      * @throws SQLException if the columnIndex is not valid;
3063      * if the driver does not support national
3064      *         character sets;  if the driver can detect that a data conversion
3065      *  error could occur; this method is called on a closed result set;
3066      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3067      * or if a database access error occurs
3068      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3069      * this method
3070      * @since 1.6
3071      */
updateNString(int columnIndex, String nString)3072     void updateNString(int columnIndex, String nString) throws SQLException;
3073 
3074     /**
3075      * Updates the designated column with a <code>String</code> value.
3076      * It is intended for use when updating <code>NCHAR</code>,<code>NVARCHAR</code>
3077      * and <code>LONGNVARCHAR</code> columns.
3078      * The updater methods are used to update column values in the
3079      * current row or the insert row.  The updater methods do not
3080      * update the underlying database; instead the <code>updateRow</code> or
3081      * <code>insertRow</code> methods are called to update the database.
3082      *
3083      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3084      * @param nString the value for the column to be updated
3085      * @throws SQLException if the columnLabel is not valid;
3086      * if the driver does not support national
3087      *         character sets;  if the driver can detect that a data conversion
3088      *  error could occur; this method is called on a closed result set;
3089      * the result set concurrency is <CODE>CONCUR_READ_ONLY</code>
3090      *  or if a database access error occurs
3091      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3092      * this method
3093      * @since 1.6
3094      */
updateNString(String columnLabel, String nString)3095     void updateNString(String columnLabel, String nString) throws SQLException;
3096 
3097     /**
3098      * Updates the designated column with a <code>java.sql.NClob</code> value.
3099      * The updater methods are used to update column values in the
3100      * current row or the insert row.  The updater methods do not
3101      * update the underlying database; instead the <code>updateRow</code> or
3102      * <code>insertRow</code> methods are called to update the database.
3103      *
3104      * @param columnIndex the first column is 1, the second 2, ...
3105      * @param nClob the value for the column to be updated
3106      * @throws SQLException if the columnIndex is not valid;
3107      * if the driver does not support national
3108      *         character sets;  if the driver can detect that a data conversion
3109      *  error could occur; this method is called on a closed result set;
3110      * if a database access error occurs or
3111      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3112      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3113      * this method
3114      * @since 1.6
3115      */
updateNClob(int columnIndex, NClob nClob)3116     void updateNClob(int columnIndex, NClob nClob) throws SQLException;
3117 
3118     /**
3119      * Updates the designated column with a <code>java.sql.NClob</code> value.
3120      * The updater methods are used to update column values in the
3121      * current row or the insert row.  The updater methods do not
3122      * update the underlying database; instead the <code>updateRow</code> or
3123      * <code>insertRow</code> methods are called to update the database.
3124      *
3125      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3126      * @param nClob the value for the column to be updated
3127      * @throws SQLException if the columnLabel is not valid;
3128      * if the driver does not support national
3129      *         character sets;  if the driver can detect that a data conversion
3130      *  error could occur; this method is called on a closed result set;
3131      *  if a database access error occurs or
3132      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3133      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3134      * this method
3135      * @since 1.6
3136      */
updateNClob(String columnLabel, NClob nClob)3137     void updateNClob(String columnLabel, NClob nClob) throws SQLException;
3138 
3139     /**
3140      * Retrieves the value of the designated column in the current row
3141      * of this <code>ResultSet</code> object as a <code>NClob</code> object
3142      * in the Java programming language.
3143      *
3144      * @param columnIndex the first column is 1, the second is 2, ...
3145      * @return a <code>NClob</code> object representing the SQL
3146      *         <code>NCLOB</code> value in the specified column
3147      * @exception SQLException if the columnIndex is not valid;
3148      * if the driver does not support national
3149      *         character sets;  if the driver can detect that a data conversion
3150      *  error could occur; this method is called on a closed result set
3151      * or if a database access error occurs
3152      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3153      * this method
3154      * @since 1.6
3155      */
getNClob(int columnIndex)3156     NClob getNClob(int columnIndex) throws SQLException;
3157 
3158   /**
3159      * Retrieves the value of the designated column in the current row
3160      * of this <code>ResultSet</code> object as a <code>NClob</code> object
3161      * in the Java programming language.
3162      *
3163      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3164      * @return a <code>NClob</code> object representing the SQL <code>NCLOB</code>
3165      * value in the specified column
3166      * @exception SQLException if the columnLabel is not valid;
3167    * if the driver does not support national
3168      *         character sets;  if the driver can detect that a data conversion
3169      *  error could occur; this method is called on a closed result set
3170      * or if a database access error occurs
3171      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3172      * this method
3173      * @since 1.6
3174      */
getNClob(String columnLabel)3175     NClob getNClob(String columnLabel) throws SQLException;
3176 
3177     /**
3178      * Retrieves the value of the designated column in  the current row of
3179      *  this <code>ResultSet</code> as a
3180      * <code>java.sql.SQLXML</code> object in the Java programming language.
3181      * @param columnIndex the first column is 1, the second is 2, ...
3182      * @return a <code>SQLXML</code> object that maps an <code>SQL XML</code> value
3183      * @throws SQLException if the columnIndex is not valid;
3184      * if a database access error occurs
3185      * or this method is called on a closed result set
3186      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3187      * this method
3188      * @since 1.6
3189      */
getSQLXML(int columnIndex)3190     SQLXML getSQLXML(int columnIndex) throws SQLException;
3191 
3192     /**
3193      * Retrieves the value of the designated column in  the current row of
3194      *  this <code>ResultSet</code> as a
3195      * <code>java.sql.SQLXML</code> object in the Java programming language.
3196      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3197      * @return a <code>SQLXML</code> object that maps an <code>SQL XML</code> value
3198      * @throws SQLException if the columnLabel is not valid;
3199      * if a database access error occurs
3200      * or this method is called on a closed result set
3201      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3202      * this method
3203      * @since 1.6
3204      */
getSQLXML(String columnLabel)3205     SQLXML getSQLXML(String columnLabel) throws SQLException;
3206     /**
3207      * Updates the designated column with a <code>java.sql.SQLXML</code> value.
3208      * The updater
3209      * methods are used to update column values in the current row or the insert
3210      * row. The updater methods do not update the underlying database; instead
3211      * the <code>updateRow</code> or <code>insertRow</code> methods are called
3212      * to update the database.
3213      * <p>
3214      *
3215      * @param columnIndex the first column is 1, the second 2, ...
3216      * @param xmlObject the value for the column to be updated
3217      * @throws SQLException if the columnIndex is not valid;
3218      * if a database access error occurs; this method
3219      *  is called on a closed result set;
3220      * the <code>java.xml.transform.Result</code>,
3221      *  <code>Writer</code> or <code>OutputStream</code> has not been closed
3222      * for the <code>SQLXML</code> object;
3223      *  if there is an error processing the XML value or
3224      * the result set concurrency is <code>CONCUR_READ_ONLY</code>.  The <code>getCause</code> method
3225      *  of the exception may provide a more detailed exception, for example, if the
3226      *  stream does not contain valid XML.
3227      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3228      * this method
3229      * @since 1.6
3230      */
updateSQLXML(int columnIndex, SQLXML xmlObject)3231     void updateSQLXML(int columnIndex, SQLXML xmlObject) throws SQLException;
3232     /**
3233      * Updates the designated column with a <code>java.sql.SQLXML</code> value.
3234      * The updater
3235      * methods are used to update column values in the current row or the insert
3236      * row. The updater methods do not update the underlying database; instead
3237      * the <code>updateRow</code> or <code>insertRow</code> methods are called
3238      * to update the database.
3239      * <p>
3240      *
3241      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3242      * @param xmlObject the column value
3243      * @throws SQLException if the columnLabel is not valid;
3244      * if a database access error occurs; this method
3245      *  is called on a closed result set;
3246      * the <code>java.xml.transform.Result</code>,
3247      *  <code>Writer</code> or <code>OutputStream</code> has not been closed
3248      * for the <code>SQLXML</code> object;
3249      *  if there is an error processing the XML value or
3250      * the result set concurrency is <code>CONCUR_READ_ONLY</code>.  The <code>getCause</code> method
3251      *  of the exception may provide a more detailed exception, for example, if the
3252      *  stream does not contain valid XML.
3253      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3254      * this method
3255      * @since 1.6
3256      */
updateSQLXML(String columnLabel, SQLXML xmlObject)3257     void updateSQLXML(String columnLabel, SQLXML xmlObject) throws SQLException;
3258 
3259     /**
3260      * Retrieves the value of the designated column in the current row
3261      * of this <code>ResultSet</code> object as
3262      * a <code>String</code> in the Java programming language.
3263      * It is intended for use when
3264      * accessing  <code>NCHAR</code>,<code>NVARCHAR</code>
3265      * and <code>LONGNVARCHAR</code> columns.
3266      *
3267      * @param columnIndex the first column is 1, the second is 2, ...
3268      * @return the column value; if the value is SQL <code>NULL</code>, the
3269      * value returned is <code>null</code>
3270      * @exception SQLException if the columnIndex is not valid;
3271      * if a database access error occurs
3272      * or this method is called on a closed result set
3273      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3274      * this method
3275      * @since 1.6
3276      */
getNString(int columnIndex)3277     String getNString(int columnIndex) throws SQLException;
3278 
3279 
3280     /**
3281      * Retrieves the value of the designated column in the current row
3282      * of this <code>ResultSet</code> object as
3283      * a <code>String</code> in the Java programming language.
3284      * It is intended for use when
3285      * accessing  <code>NCHAR</code>,<code>NVARCHAR</code>
3286      * and <code>LONGNVARCHAR</code> columns.
3287      *
3288      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3289      * @return the column value; if the value is SQL <code>NULL</code>, the
3290      * value returned is <code>null</code>
3291      * @exception SQLException if the columnLabel is not valid;
3292      * if a database access error occurs
3293      * or this method is called on a closed result set
3294      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3295      * this method
3296      * @since 1.6
3297      */
getNString(String columnLabel)3298     String getNString(String columnLabel) throws SQLException;
3299 
3300 
3301     /**
3302      * Retrieves the value of the designated column in the current row
3303      * of this <code>ResultSet</code> object as a
3304      * <code>java.io.Reader</code> object.
3305      * It is intended for use when
3306      * accessing  <code>NCHAR</code>,<code>NVARCHAR</code>
3307      * and <code>LONGNVARCHAR</code> columns.
3308      *
3309      * @return a <code>java.io.Reader</code> object that contains the column
3310      * value; if the value is SQL <code>NULL</code>, the value returned is
3311      * <code>null</code> in the Java programming language.
3312      * @param columnIndex the first column is 1, the second is 2, ...
3313      * @exception SQLException if the columnIndex is not valid;
3314      * if a database access error occurs
3315      * or this method is called on a closed result set
3316      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3317      * this method
3318      * @since 1.6
3319      */
getNCharacterStream(int columnIndex)3320     java.io.Reader getNCharacterStream(int columnIndex) throws SQLException;
3321 
3322     /**
3323      * Retrieves the value of the designated column in the current row
3324      * of this <code>ResultSet</code> object as a
3325      * <code>java.io.Reader</code> object.
3326      * It is intended for use when
3327      * accessing  <code>NCHAR</code>,<code>NVARCHAR</code>
3328      * and <code>LONGNVARCHAR</code> columns.
3329      *
3330      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3331      * @return a <code>java.io.Reader</code> object that contains the column
3332      * value; if the value is SQL <code>NULL</code>, the value returned is
3333      * <code>null</code> in the Java programming language
3334      * @exception SQLException if the columnLabel is not valid;
3335      * if a database access error occurs
3336      * or this method is called on a closed result set
3337      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3338      * this method
3339      * @since 1.6
3340      */
getNCharacterStream(String columnLabel)3341     java.io.Reader getNCharacterStream(String columnLabel) throws SQLException;
3342 
3343     /**
3344      * Updates the designated column with a character stream value, which will have
3345      * the specified number of bytes.   The
3346      * driver does the necessary conversion from Java character format to
3347      * the national character set in the database.
3348      * It is intended for use when
3349      * updating  <code>NCHAR</code>,<code>NVARCHAR</code>
3350      * and <code>LONGNVARCHAR</code> columns.
3351      * <p>
3352      * The updater methods are used to update column values in the
3353      * current row or the insert row.  The updater methods do not
3354      * update the underlying database; instead the <code>updateRow</code> or
3355      * <code>insertRow</code> methods are called to update the database.
3356      *
3357      * @param columnIndex the first column is 1, the second is 2, ...
3358      * @param x the new column value
3359      * @param length the length of the stream
3360      * @exception SQLException if the columnIndex is not valid;
3361      * if a database access error occurs;
3362      * the result set concurrency is <code>CONCUR_READ_ONLY</code> or this method is called on a closed result set
3363      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3364      * this method
3365      * @since 1.6
3366      */
updateNCharacterStream(int columnIndex, java.io.Reader x, long length)3367     void updateNCharacterStream(int columnIndex,
3368                              java.io.Reader x,
3369                              long length) throws SQLException;
3370 
3371     /**
3372      * Updates the designated column with a character stream value, which will have
3373      * the specified number of bytes.  The
3374      * driver does the necessary conversion from Java character format to
3375      * the national character set in the database.
3376      * It is intended for use when
3377      * updating  <code>NCHAR</code>,<code>NVARCHAR</code>
3378      * and <code>LONGNVARCHAR</code> columns.
3379      * <p>
3380      * The updater methods are used to update column values in the
3381      * current row or the insert row.  The updater methods do not
3382      * update the underlying database; instead the <code>updateRow</code> or
3383      * <code>insertRow</code> methods are called to update the database.
3384      *
3385      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3386      * @param reader the <code>java.io.Reader</code> object containing
3387      *        the new column value
3388      * @param length the length of the stream
3389      * @exception SQLException if the columnLabel is not valid;
3390      * if a database access error occurs;
3391      * the result set concurrency is <code>CONCUR_READ_ONLY</code> or this method is called on a closed result set
3392       * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3393      * this method
3394      * @since 1.6
3395      */
updateNCharacterStream(String columnLabel, java.io.Reader reader, long length)3396     void updateNCharacterStream(String columnLabel,
3397                              java.io.Reader reader,
3398                              long length) throws SQLException;
3399     /**
3400      * Updates the designated column with an ascii stream value, which will have
3401      * the specified number of bytes.
3402      * <p>
3403      * The updater methods are used to update column values in the
3404      * current row or the insert row.  The updater methods do not
3405      * update the underlying database; instead the <code>updateRow</code> or
3406      * <code>insertRow</code> methods are called to update the database.
3407      *
3408      * @param columnIndex the first column is 1, the second is 2, ...
3409      * @param x the new column value
3410      * @param length the length of the stream
3411      * @exception SQLException if the columnIndex is not valid;
3412      * if a database access error occurs;
3413      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3414      * or this method is called on a closed result set
3415      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3416      * this method
3417      * @since 1.6
3418      */
updateAsciiStream(int columnIndex, java.io.InputStream x, long length)3419     void updateAsciiStream(int columnIndex,
3420                            java.io.InputStream x,
3421                            long length) throws SQLException;
3422 
3423     /**
3424      * Updates the designated column with a binary stream value, which will have
3425      * the specified number of bytes.
3426      * <p>
3427      * The updater methods are used to update column values in the
3428      * current row or the insert row.  The updater methods do not
3429      * update the underlying database; instead the <code>updateRow</code> or
3430      * <code>insertRow</code> methods are called to update the database.
3431      *
3432      * @param columnIndex the first column is 1, the second is 2, ...
3433      * @param x the new column value
3434      * @param length the length of the stream
3435      * @exception SQLException if the columnIndex is not valid;
3436      * if a database access error occurs;
3437      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3438      * or this method is called on a closed result set
3439      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3440      * this method
3441      * @since 1.6
3442      */
updateBinaryStream(int columnIndex, java.io.InputStream x, long length)3443     void updateBinaryStream(int columnIndex,
3444                             java.io.InputStream x,
3445                             long length) throws SQLException;
3446 
3447     /**
3448      * Updates the designated column with a character stream value, which will have
3449      * the specified number of bytes.
3450      * <p>
3451      * The updater methods are used to update column values in the
3452      * current row or the insert row.  The updater methods do not
3453      * update the underlying database; instead the <code>updateRow</code> or
3454      * <code>insertRow</code> methods are called to update the database.
3455      *
3456      * @param columnIndex the first column is 1, the second is 2, ...
3457      * @param x the new column value
3458      * @param length the length of the stream
3459      * @exception SQLException if the columnIndex is not valid;
3460      * if a database access error occurs;
3461      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3462      * or this method is called on a closed result set
3463      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3464      * this method
3465      * @since 1.6
3466      */
updateCharacterStream(int columnIndex, java.io.Reader x, long length)3467     void updateCharacterStream(int columnIndex,
3468                              java.io.Reader x,
3469                              long length) throws SQLException;
3470     /**
3471      * Updates the designated column with an ascii stream value, which will have
3472      * the specified number of bytes.
3473      * <p>
3474      * The updater methods are used to update column values in the
3475      * current row or the insert row.  The updater methods do not
3476      * update the underlying database; instead the <code>updateRow</code> or
3477      * <code>insertRow</code> methods are called to update the database.
3478      *
3479      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3480      * @param x the new column value
3481      * @param length the length of the stream
3482      * @exception SQLException if the columnLabel is not valid;
3483      * if a database access error occurs;
3484      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3485      * or this method is called on a closed result set
3486      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3487      * this method
3488      * @since 1.6
3489      */
updateAsciiStream(String columnLabel, java.io.InputStream x, long length)3490     void updateAsciiStream(String columnLabel,
3491                            java.io.InputStream x,
3492                            long length) throws SQLException;
3493 
3494     /**
3495      * Updates the designated column with a binary stream value, which will have
3496      * the specified number of bytes.
3497      * <p>
3498      * The updater methods are used to update column values in the
3499      * current row or the insert row.  The updater methods do not
3500      * update the underlying database; instead the <code>updateRow</code> or
3501      * <code>insertRow</code> methods are called to update the database.
3502      *
3503      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3504      * @param x the new column value
3505      * @param length the length of the stream
3506      * @exception SQLException if the columnLabel is not valid;
3507      * if a database access error occurs;
3508      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3509      * or this method is called on a closed result set
3510      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3511      * this method
3512      * @since 1.6
3513      */
updateBinaryStream(String columnLabel, java.io.InputStream x, long length)3514     void updateBinaryStream(String columnLabel,
3515                             java.io.InputStream x,
3516                             long length) throws SQLException;
3517 
3518     /**
3519      * Updates the designated column with a character stream value, which will have
3520      * the specified number of bytes.
3521      * <p>
3522      * The updater methods are used to update column values in the
3523      * current row or the insert row.  The updater methods do not
3524      * update the underlying database; instead the <code>updateRow</code> or
3525      * <code>insertRow</code> methods are called to update the database.
3526      *
3527      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3528      * @param reader the <code>java.io.Reader</code> object containing
3529      *        the new column value
3530      * @param length the length of the stream
3531      * @exception SQLException if the columnLabel is not valid;
3532      * if a database access error occurs;
3533      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3534      * or this method is called on a closed result set
3535      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3536      * this method
3537      * @since 1.6
3538      */
updateCharacterStream(String columnLabel, java.io.Reader reader, long length)3539     void updateCharacterStream(String columnLabel,
3540                              java.io.Reader reader,
3541                              long length) throws SQLException;
3542     /**
3543      * Updates the designated column using the given input stream, which
3544      * will have the specified number of bytes.
3545      *
3546      * <p>
3547      * The updater methods are used to update column values in the
3548      * current row or the insert row.  The updater methods do not
3549      * update the underlying database; instead the <code>updateRow</code> or
3550      * <code>insertRow</code> methods are called to update the database.
3551      *
3552      * @param columnIndex the first column is 1, the second is 2, ...
3553      * @param inputStream An object that contains the data to set the parameter
3554      * value to.
3555      * @param length the number of bytes in the parameter data.
3556      * @exception SQLException if the columnIndex is not valid;
3557      * if a database access error occurs;
3558      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3559      * or this method is called on a closed result set
3560      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3561      * this method
3562      * @since 1.6
3563      */
updateBlob(int columnIndex, InputStream inputStream, long length)3564     void updateBlob(int columnIndex, InputStream inputStream, long length) throws SQLException;
3565 
3566     /**
3567      * Updates the designated column using the given input stream, which
3568      * will have the specified number of bytes.
3569      *
3570      * <p>
3571      * The updater methods are used to update column values in the
3572      * current row or the insert row.  The updater methods do not
3573      * update the underlying database; instead the <code>updateRow</code> or
3574      * <code>insertRow</code> methods are called to update the database.
3575      *
3576      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3577      * @param inputStream An object that contains the data to set the parameter
3578      * value to.
3579      * @param length the number of bytes in the parameter data.
3580      * @exception SQLException if the columnLabel is not valid;
3581      * if a database access error occurs;
3582      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3583      * or this method is called on a closed result set
3584      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3585      * this method
3586      * @since 1.6
3587      */
updateBlob(String columnLabel, InputStream inputStream, long length)3588     void updateBlob(String columnLabel, InputStream inputStream, long length) throws SQLException;
3589 
3590     /**
3591      * Updates the designated column using the given <code>Reader</code>
3592      * object, which is the given number of characters long.
3593      * When a very large UNICODE value is input to a <code>LONGVARCHAR</code>
3594      * parameter, it may be more practical to send it via a
3595      * <code>java.io.Reader</code> object. The JDBC driver will
3596      * do any necessary conversion from UNICODE to the database char format.
3597      *
3598      * <p>
3599      * The updater methods are used to update column values in the
3600      * current row or the insert row.  The updater methods do not
3601      * update the underlying database; instead the <code>updateRow</code> or
3602      * <code>insertRow</code> methods are called to update the database.
3603      *
3604      * @param columnIndex the first column is 1, the second is 2, ...
3605      * @param reader An object that contains the data to set the parameter value to.
3606      * @param length the number of characters in the parameter data.
3607      * @exception SQLException if the columnIndex is not valid;
3608      * if a database access error occurs;
3609      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3610      * or this method is called on a closed result set
3611      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3612      * this method
3613      * @since 1.6
3614      */
updateClob(int columnIndex, Reader reader, long length)3615     void updateClob(int columnIndex,  Reader reader, long length) throws SQLException;
3616 
3617     /**
3618      * Updates the designated column using the given <code>Reader</code>
3619      * object, which is the given number of characters long.
3620      * When a very large UNICODE value is input to a <code>LONGVARCHAR</code>
3621      * parameter, it may be more practical to send it via a
3622      * <code>java.io.Reader</code> object.  The JDBC driver will
3623      * do any necessary conversion from UNICODE to the database char format.
3624      *
3625      * <p>
3626      * The updater methods are used to update column values in the
3627      * current row or the insert row.  The updater methods do not
3628      * update the underlying database; instead the <code>updateRow</code> or
3629      * <code>insertRow</code> methods are called to update the database.
3630      *
3631      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3632      * @param reader An object that contains the data to set the parameter value to.
3633      * @param length the number of characters in the parameter data.
3634      * @exception SQLException if the columnLabel is not valid;
3635      * if a database access error occurs;
3636      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3637      * or this method is called on a closed result set
3638      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3639      * this method
3640      * @since 1.6
3641      */
updateClob(String columnLabel, Reader reader, long length)3642     void updateClob(String columnLabel,  Reader reader, long length) throws SQLException;
3643    /**
3644      * Updates the designated column using the given <code>Reader</code>
3645      * object, which is the given number of characters long.
3646      * When a very large UNICODE value is input to a <code>LONGVARCHAR</code>
3647      * parameter, it may be more practical to send it via a
3648      * <code>java.io.Reader</code> object. The JDBC driver will
3649      * do any necessary conversion from UNICODE to the database char format.
3650      *
3651      * <p>
3652      * The updater methods are used to update column values in the
3653      * current row or the insert row.  The updater methods do not
3654      * update the underlying database; instead the <code>updateRow</code> or
3655      * <code>insertRow</code> methods are called to update the database.
3656      *
3657      * @param columnIndex the first column is 1, the second 2, ...
3658      * @param reader An object that contains the data to set the parameter value to.
3659      * @param length the number of characters in the parameter data.
3660      * @throws SQLException if the columnIndex is not valid;
3661     * if the driver does not support national
3662      *         character sets;  if the driver can detect that a data conversion
3663      *  error could occur; this method is called on a closed result set,
3664      * if a database access error occurs or
3665      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3666      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3667      * this method
3668      * @since 1.6
3669      */
updateNClob(int columnIndex, Reader reader, long length)3670     void updateNClob(int columnIndex,  Reader reader, long length) throws SQLException;
3671 
3672     /**
3673      * Updates the designated column using the given <code>Reader</code>
3674      * object, which is the given number of characters long.
3675      * When a very large UNICODE value is input to a <code>LONGVARCHAR</code>
3676      * parameter, it may be more practical to send it via a
3677      * <code>java.io.Reader</code> object. The JDBC driver will
3678      * do any necessary conversion from UNICODE to the database char format.
3679      *
3680      * <p>
3681      * The updater methods are used to update column values in the
3682      * current row or the insert row.  The updater methods do not
3683      * update the underlying database; instead the <code>updateRow</code> or
3684      * <code>insertRow</code> methods are called to update the database.
3685      *
3686      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3687      * @param reader An object that contains the data to set the parameter value to.
3688      * @param length the number of characters in the parameter data.
3689      * @throws SQLException if the columnLabel is not valid;
3690      * if the driver does not support national
3691      *         character sets;  if the driver can detect that a data conversion
3692      *  error could occur; this method is called on a closed result set;
3693      *  if a database access error occurs or
3694      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3695      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3696      * this method
3697      * @since 1.6
3698      */
updateNClob(String columnLabel, Reader reader, long length)3699     void updateNClob(String columnLabel,  Reader reader, long length) throws SQLException;
3700 
3701     //---
3702 
3703     /**
3704      * Updates the designated column with a character stream value.
3705      * The data will be read from the stream
3706      * as needed until end-of-stream is reached.  The
3707      * driver does the necessary conversion from Java character format to
3708      * the national character set in the database.
3709      * It is intended for use when
3710      * updating  <code>NCHAR</code>,<code>NVARCHAR</code>
3711      * and <code>LONGNVARCHAR</code> columns.
3712      * <p>
3713      * The updater methods are used to update column values in the
3714      * current row or the insert row.  The updater methods do not
3715      * update the underlying database; instead the <code>updateRow</code> or
3716      * <code>insertRow</code> methods are called to update the database.
3717      *
3718      * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3719      * it might be more efficient to use a version of
3720      * <code>updateNCharacterStream</code> which takes a length parameter.
3721      *
3722      * @param columnIndex the first column is 1, the second is 2, ...
3723      * @param x the new column value
3724      * @exception SQLException if the columnIndex is not valid;
3725      * if a database access error occurs;
3726      * the result set concurrency is <code>CONCUR_READ_ONLY</code> or this method is called on a closed result set
3727      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3728      * this method
3729      * @since 1.6
3730      */
updateNCharacterStream(int columnIndex, java.io.Reader x)3731     void updateNCharacterStream(int columnIndex,
3732                              java.io.Reader x) throws SQLException;
3733 
3734     /**
3735      * Updates the designated column with a character stream value.
3736      * The data will be read from the stream
3737      * as needed until end-of-stream is reached.  The
3738      * driver does the necessary conversion from Java character format to
3739      * the national character set in the database.
3740      * It is intended for use when
3741      * updating  <code>NCHAR</code>,<code>NVARCHAR</code>
3742      * and <code>LONGNVARCHAR</code> columns.
3743      * <p>
3744      * The updater methods are used to update column values in the
3745      * current row or the insert row.  The updater methods do not
3746      * update the underlying database; instead the <code>updateRow</code> or
3747      * <code>insertRow</code> methods are called to update the database.
3748      *
3749      * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3750      * it might be more efficient to use a version of
3751      * <code>updateNCharacterStream</code> which takes a length parameter.
3752      *
3753      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3754      * @param reader the <code>java.io.Reader</code> object containing
3755      *        the new column value
3756      * @exception SQLException if the columnLabel is not valid;
3757      * if a database access error occurs;
3758      * the result set concurrency is <code>CONCUR_READ_ONLY</code> or this method is called on a closed result set
3759       * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3760      * this method
3761      * @since 1.6
3762      */
updateNCharacterStream(String columnLabel, java.io.Reader reader)3763     void updateNCharacterStream(String columnLabel,
3764                              java.io.Reader reader) throws SQLException;
3765     /**
3766      * Updates the designated column with an ascii stream value.
3767      * The data will be read from the stream
3768      * as needed until end-of-stream is reached.
3769      * <p>
3770      * The updater methods are used to update column values in the
3771      * current row or the insert row.  The updater methods do not
3772      * update the underlying database; instead the <code>updateRow</code> or
3773      * <code>insertRow</code> methods are called to update the database.
3774      *
3775      * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3776      * it might be more efficient to use a version of
3777      * <code>updateAsciiStream</code> which takes a length parameter.
3778      *
3779      * @param columnIndex the first column is 1, the second is 2, ...
3780      * @param x the new column value
3781      * @exception SQLException if the columnIndex is not valid;
3782      * if a database access error occurs;
3783      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3784      * or this method is called on a closed result set
3785      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3786      * this method
3787      * @since 1.6
3788      */
updateAsciiStream(int columnIndex, java.io.InputStream x)3789     void updateAsciiStream(int columnIndex,
3790                            java.io.InputStream x) throws SQLException;
3791 
3792     /**
3793      * Updates the designated column with a binary stream value.
3794      * The data will be read from the stream
3795      * as needed until end-of-stream is reached.
3796      * <p>
3797      * The updater methods are used to update column values in the
3798      * current row or the insert row.  The updater methods do not
3799      * update the underlying database; instead the <code>updateRow</code> or
3800      * <code>insertRow</code> methods are called to update the database.
3801      *
3802      * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3803      * it might be more efficient to use a version of
3804      * <code>updateBinaryStream</code> which takes a length parameter.
3805      *
3806      * @param columnIndex the first column is 1, the second is 2, ...
3807      * @param x the new column value
3808      * @exception SQLException if the columnIndex is not valid;
3809      * if a database access error occurs;
3810      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3811      * or this method is called on a closed result set
3812      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3813      * this method
3814      * @since 1.6
3815      */
updateBinaryStream(int columnIndex, java.io.InputStream x)3816     void updateBinaryStream(int columnIndex,
3817                             java.io.InputStream x) throws SQLException;
3818 
3819     /**
3820      * Updates the designated column with a character stream value.
3821      * The data will be read from the stream
3822      * as needed until end-of-stream is reached.
3823      * <p>
3824      * The updater methods are used to update column values in the
3825      * current row or the insert row.  The updater methods do not
3826      * update the underlying database; instead the <code>updateRow</code> or
3827      * <code>insertRow</code> methods are called to update the database.
3828      *
3829      * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3830      * it might be more efficient to use a version of
3831      * <code>updateCharacterStream</code> which takes a length parameter.
3832      *
3833      * @param columnIndex the first column is 1, the second is 2, ...
3834      * @param x the new column value
3835      * @exception SQLException if the columnIndex is not valid;
3836      * if a database access error occurs;
3837      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3838      * or this method is called on a closed result set
3839      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3840      * this method
3841      * @since 1.6
3842      */
updateCharacterStream(int columnIndex, java.io.Reader x)3843     void updateCharacterStream(int columnIndex,
3844                              java.io.Reader x) throws SQLException;
3845     /**
3846      * Updates the designated column with an ascii stream value.
3847      * The data will be read from the stream
3848      * as needed until end-of-stream is reached.
3849      * <p>
3850      * The updater methods are used to update column values in the
3851      * current row or the insert row.  The updater methods do not
3852      * update the underlying database; instead the <code>updateRow</code> or
3853      * <code>insertRow</code> methods are called to update the database.
3854      *
3855      * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3856      * it might be more efficient to use a version of
3857      * <code>updateAsciiStream</code> which takes a length parameter.
3858      *
3859      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3860      * @param x the new column value
3861      * @exception SQLException if the columnLabel is not valid;
3862      * if a database access error occurs;
3863      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3864      * or this method is called on a closed result set
3865      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3866      * this method
3867      * @since 1.6
3868      */
updateAsciiStream(String columnLabel, java.io.InputStream x)3869     void updateAsciiStream(String columnLabel,
3870                            java.io.InputStream x) throws SQLException;
3871 
3872     /**
3873      * Updates the designated column with a binary stream value.
3874      * The data will be read from the stream
3875      * as needed until end-of-stream is reached.
3876      * <p>
3877      * The updater methods are used to update column values in the
3878      * current row or the insert row.  The updater methods do not
3879      * update the underlying database; instead the <code>updateRow</code> or
3880      * <code>insertRow</code> methods are called to update the database.
3881      *
3882      * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3883      * it might be more efficient to use a version of
3884      * <code>updateBinaryStream</code> which takes a length parameter.
3885      *
3886      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3887      * @param x the new column value
3888      * @exception SQLException if the columnLabel is not valid;
3889      * if a database access error occurs;
3890      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3891      * or this method is called on a closed result set
3892      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3893      * this method
3894      * @since 1.6
3895      */
updateBinaryStream(String columnLabel, java.io.InputStream x)3896     void updateBinaryStream(String columnLabel,
3897                             java.io.InputStream x) throws SQLException;
3898 
3899     /**
3900      * Updates the designated column with a character stream value.
3901      * The data will be read from the stream
3902      * as needed until end-of-stream is reached.
3903      * <p>
3904      * The updater methods are used to update column values in the
3905      * current row or the insert row.  The updater methods do not
3906      * update the underlying database; instead the <code>updateRow</code> or
3907      * <code>insertRow</code> methods are called to update the database.
3908      *
3909      * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3910      * it might be more efficient to use a version of
3911      * <code>updateCharacterStream</code> which takes a length parameter.
3912      *
3913      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3914      * @param reader the <code>java.io.Reader</code> object containing
3915      *        the new column value
3916      * @exception SQLException if the columnLabel is not valid; if a database access error occurs;
3917      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3918      * or this method is called on a closed result set
3919      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3920      * this method
3921      * @since 1.6
3922      */
updateCharacterStream(String columnLabel, java.io.Reader reader)3923     void updateCharacterStream(String columnLabel,
3924                              java.io.Reader reader) throws SQLException;
3925     /**
3926      * Updates the designated column using the given input stream. The data will be read from the stream
3927      * as needed until end-of-stream is reached.
3928      * <p>
3929      * The updater methods are used to update column values in the
3930      * current row or the insert row.  The updater methods do not
3931      * update the underlying database; instead the <code>updateRow</code> or
3932      * <code>insertRow</code> methods are called to update the database.
3933      *
3934      * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3935      * it might be more efficient to use a version of
3936      * <code>updateBlob</code> which takes a length parameter.
3937      *
3938      * @param columnIndex the first column is 1, the second is 2, ...
3939      * @param inputStream An object that contains the data to set the parameter
3940      * value to.
3941      * @exception SQLException if the columnIndex is not valid; if a database access error occurs;
3942      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3943      * or this method is called on a closed result set
3944      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3945      * this method
3946      * @since 1.6
3947      */
updateBlob(int columnIndex, InputStream inputStream)3948     void updateBlob(int columnIndex, InputStream inputStream) throws SQLException;
3949 
3950     /**
3951      * Updates the designated column using the given input stream. The data will be read from the stream
3952      * as needed until end-of-stream is reached.
3953      * <p>
3954      * The updater methods are used to update column values in the
3955      * current row or the insert row.  The updater methods do not
3956      * update the underlying database; instead the <code>updateRow</code> or
3957      * <code>insertRow</code> methods are called to update the database.
3958      *
3959      *   <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3960      * it might be more efficient to use a version of
3961      * <code>updateBlob</code> which takes a length parameter.
3962      *
3963      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
3964      * @param inputStream An object that contains the data to set the parameter
3965      * value to.
3966      * @exception SQLException if the columnLabel is not valid; if a database access error occurs;
3967      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3968      * or this method is called on a closed result set
3969      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3970      * this method
3971      * @since 1.6
3972      */
updateBlob(String columnLabel, InputStream inputStream)3973     void updateBlob(String columnLabel, InputStream inputStream) throws SQLException;
3974 
3975     /**
3976      * Updates the designated column using the given <code>Reader</code>
3977      * object.
3978      *  The data will be read from the stream
3979      * as needed until end-of-stream is reached.  The JDBC driver will
3980      * do any necessary conversion from UNICODE to the database char format.
3981      *
3982      * <p>
3983      * The updater methods are used to update column values in the
3984      * current row or the insert row.  The updater methods do not
3985      * update the underlying database; instead the <code>updateRow</code> or
3986      * <code>insertRow</code> methods are called to update the database.
3987      *
3988      *   <P><B>Note:</B> Consult your JDBC driver documentation to determine if
3989      * it might be more efficient to use a version of
3990      * <code>updateClob</code> which takes a length parameter.
3991      *
3992      * @param columnIndex the first column is 1, the second is 2, ...
3993      * @param reader An object that contains the data to set the parameter value to.
3994      * @exception SQLException if the columnIndex is not valid;
3995      * if a database access error occurs;
3996      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
3997      * or this method is called on a closed result set
3998      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
3999      * this method
4000      * @since 1.6
4001      */
updateClob(int columnIndex, Reader reader)4002     void updateClob(int columnIndex,  Reader reader) throws SQLException;
4003 
4004     /**
4005      * Updates the designated column using the given <code>Reader</code>
4006      * object.
4007      *  The data will be read from the stream
4008      * as needed until end-of-stream is reached.  The JDBC driver will
4009      * do any necessary conversion from UNICODE to the database char format.
4010      *
4011      * <p>
4012      * The updater methods are used to update column values in the
4013      * current row or the insert row.  The updater methods do not
4014      * update the underlying database; instead the <code>updateRow</code> or
4015      * <code>insertRow</code> methods are called to update the database.
4016      *
4017      * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
4018      * it might be more efficient to use a version of
4019      * <code>updateClob</code> which takes a length parameter.
4020      *
4021      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
4022      * @param reader An object that contains the data to set the parameter value to.
4023      * @exception SQLException if the columnLabel is not valid; if a database access error occurs;
4024      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
4025      * or this method is called on a closed result set
4026      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4027      * this method
4028      * @since 1.6
4029      */
updateClob(String columnLabel, Reader reader)4030     void updateClob(String columnLabel,  Reader reader) throws SQLException;
4031    /**
4032      * Updates the designated column using the given <code>Reader</code>
4033      *
4034      * The data will be read from the stream
4035      * as needed until end-of-stream is reached.  The JDBC driver will
4036      * do any necessary conversion from UNICODE to the database char format.
4037      *
4038      * <p>
4039      * The updater methods are used to update column values in the
4040      * current row or the insert row.  The updater methods do not
4041      * update the underlying database; instead the <code>updateRow</code> or
4042      * <code>insertRow</code> methods are called to update the database.
4043      *
4044      * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
4045      * it might be more efficient to use a version of
4046      * <code>updateNClob</code> which takes a length parameter.
4047      *
4048      * @param columnIndex the first column is 1, the second 2, ...
4049      * @param reader An object that contains the data to set the parameter value to.
4050      * @throws SQLException if the columnIndex is not valid;
4051     * if the driver does not support national
4052      *         character sets;  if the driver can detect that a data conversion
4053      *  error could occur; this method is called on a closed result set,
4054      * if a database access error occurs or
4055      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
4056      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4057      * this method
4058      * @since 1.6
4059      */
updateNClob(int columnIndex, Reader reader)4060     void updateNClob(int columnIndex,  Reader reader) throws SQLException;
4061 
4062     /**
4063      * Updates the designated column using the given <code>Reader</code>
4064      * object.
4065      * The data will be read from the stream
4066      * as needed until end-of-stream is reached.  The JDBC driver will
4067      * do any necessary conversion from UNICODE to the database char format.
4068      *
4069      * <p>
4070      * The updater methods are used to update column values in the
4071      * current row or the insert row.  The updater methods do not
4072      * update the underlying database; instead the <code>updateRow</code> or
4073      * <code>insertRow</code> methods are called to update the database.
4074      *
4075      * <P><B>Note:</B> Consult your JDBC driver documentation to determine if
4076      * it might be more efficient to use a version of
4077      * <code>updateNClob</code> which takes a length parameter.
4078      *
4079      * @param columnLabel the label for the column specified with the SQL AS clause.  If the SQL AS clause was not specified, then the label is the name of the column
4080      * @param reader An object that contains the data to set the parameter value to.
4081      * @throws SQLException if the columnLabel is not valid; if the driver does not support national
4082      *         character sets;  if the driver can detect that a data conversion
4083      *  error could occur; this method is called on a closed result set;
4084      *  if a database access error occurs or
4085      * the result set concurrency is <code>CONCUR_READ_ONLY</code>
4086      * @exception SQLFeatureNotSupportedException if the JDBC driver does not support
4087      * this method
4088      * @since 1.6
4089      */
updateNClob(String columnLabel, Reader reader)4090     void updateNClob(String columnLabel,  Reader reader) throws SQLException;
4091 
4092     // Android-removed: JDBC 4.1 methods were removed immediately after the initial import.
4093 }
4094