Path: blob/master/src/java.sql/share/classes/java/sql/ResultSet.java
41153 views
/*1* Copyright (c) 1996, 2020, Oracle and/or its affiliates. All rights reserved.2* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.3*4* This code is free software; you can redistribute it and/or modify it5* under the terms of the GNU General Public License version 2 only, as6* published by the Free Software Foundation. Oracle designates this7* particular file as subject to the "Classpath" exception as provided8* by Oracle in the LICENSE file that accompanied this code.9*10* This code is distributed in the hope that it will be useful, but WITHOUT11* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or12* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License13* version 2 for more details (a copy is included in the LICENSE file that14* accompanied this code).15*16* You should have received a copy of the GNU General Public License version17* 2 along with this work; if not, write to the Free Software Foundation,18* Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.19*20* Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA21* or visit www.oracle.com if you need additional information or have any22* questions.23*/2425package java.sql;2627import java.math.BigDecimal;28import java.util.Calendar;29import java.io.Reader;30import java.io.InputStream;3132/**33* A table of data representing a database result set, which34* is usually generated by executing a statement that queries the database.35*36* <P>A {@code ResultSet} object maintains a cursor pointing37* to its current row of data. Initially the cursor is positioned38* before the first row. The {@code next} method moves the39* cursor to the next row, and because it returns {@code false}40* when there are no more rows in the {@code ResultSet} object,41* it can be used in a {@code while} loop to iterate through42* the result set.43* <P>44* A default {@code ResultSet} object is not updatable and45* has a cursor that moves forward only. Thus, you can46* iterate through it only once and only from the first row to the47* last row. It is possible to48* produce {@code ResultSet} objects that are scrollable and/or49* updatable. The following code fragment, in which {@code con}50* is a valid {@code Connection} object, illustrates how to make51* a result set that is scrollable and insensitive to updates by others, and52* that is updatable. See {@code ResultSet} fields for other53* options.54* <PRE>55*56* Statement stmt = con.createStatement(57* ResultSet.TYPE_SCROLL_INSENSITIVE,58* ResultSet.CONCUR_UPDATABLE);59* ResultSet rs = stmt.executeQuery("SELECT a, b FROM TABLE2");60* // rs will be scrollable, will not show changes made by others,61* // and will be updatable62*63* </PRE>64* The {@code ResultSet} interface provides65* <i>getter</i> methods ({@code getBoolean}, {@code getLong}, and so on)66* for retrieving column values from the current row.67* Values can be retrieved using either the index number of the68* column or the name of the column. In general, using the69* column index will be more efficient. Columns are numbered from 1.70* For maximum portability, result set columns within each row should be71* read in left-to-right order, and each column should be read only once.72*73* <P>For the getter methods, a JDBC driver attempts74* to convert the underlying data to the Java type specified in the75* getter method and returns a suitable Java value. The JDBC specification76* has a table showing the allowable mappings from SQL types to Java types77* that can be used by the {@code ResultSet} getter methods.78*79* <P>Column names used as input to getter methods are case80* insensitive. When a getter method is called with81* a column name and several columns have the same name,82* the value of the first matching column will be returned.83* The column name option is84* designed to be used when column names are used in the SQL85* query that generated the result set.86* For columns that are NOT explicitly named in the query, it87* is best to use column numbers. If column names are used, the88* programmer should take care to guarantee that they uniquely refer to89* the intended columns, which can be assured with the SQL <i>AS</i> clause.90* <P>91* A set of updater methods were added to this interface92* in the JDBC 2.0 API (Java 2 SDK,93* Standard Edition, version 1.2). The comments regarding parameters94* to the getter methods also apply to parameters to the95* updater methods.96*<P>97* The updater methods may be used in two ways:98* <ol>99* <LI>to update a column value in the current row. In a scrollable100* {@code ResultSet} object, the cursor can be moved backwards101* and forwards, to an absolute position, or to a position102* relative to the current row.103* The following code fragment updates the {@code NAME} column104* in the fifth row of the {@code ResultSet} object105* {@code rs} and then uses the method {@code updateRow}106* to update the data source table from which {@code rs} was derived.107* <PRE>108*109* rs.absolute(5); // moves the cursor to the fifth row of rs110* rs.updateString("NAME", "AINSWORTH"); // updates the111* // {@code NAME} column of row 5 to be {@code AINSWORTH}112* rs.updateRow(); // updates the row in the data source113*114* </PRE>115* <LI>to insert column values into the insert row. An updatable116* {@code ResultSet} object has a special row associated with117* it that serves as a staging area for building a row to be inserted.118* The following code fragment moves the cursor to the insert row, builds119* a three-column row, and inserts it into {@code rs} and into120* the data source table using the method {@code insertRow}.121* <PRE>122*123* rs.moveToInsertRow(); // moves cursor to the insert row124* rs.updateString(1, "AINSWORTH"); // updates the125* // first column of the insert row to be {@code AINSWORTH}126* rs.updateInt(2,35); // updates the second column to be {@code 35}127* rs.updateBoolean(3, true); // updates the third column to {@code true}128* rs.insertRow();129* rs.moveToCurrentRow();130*131* </PRE>132* </ol>133* <P>A {@code ResultSet} object is automatically closed when the134* {@code Statement} object that135* generated it is closed, re-executed, or used136* to retrieve the next result from a sequence of multiple results.137*138* <P>The number, types and properties of a {@code ResultSet}139* object's columns are provided by the {@code ResultSetMetaData}140* object returned by the {@code ResultSet.getMetaData} method.141*142* @see Statement#executeQuery143* @see Statement#getResultSet144* @see ResultSetMetaData145* @since 1.1146*/147148public interface ResultSet extends Wrapper, AutoCloseable {149150/**151* Moves the cursor forward one row from its current position.152* A {@code ResultSet} cursor is initially positioned153* before the first row; the first call to the method154* {@code next} makes the first row the current row; the155* second call makes the second row the current row, and so on.156* <p>157* When a call to the {@code next} method returns {@code false},158* the cursor is positioned after the last row. Any159* invocation of a {@code ResultSet} method which requires a160* current row will result in a {@code SQLException} being thrown.161* If the result set type is {@code TYPE_FORWARD_ONLY}, it is vendor specified162* whether their JDBC driver implementation will return {@code false} or163* throw an {@code SQLException} on a164* subsequent call to {@code next}.165*166* <P>If an input stream is open for the current row, a call167* to the method {@code next} will168* implicitly close it. A {@code ResultSet} object's169* warning chain is cleared when a new row is read.170*171* @return {@code true} if the new current row is valid;172* {@code false} if there are no more rows173* @throws SQLException if a database access error occurs or this method is174* called on a closed result set175*/176boolean next() throws SQLException;177178179/**180* Releases this {@code ResultSet} object's database and181* JDBC resources immediately instead of waiting for182* this to happen when it is automatically closed.183*184* <P>The closing of a {@code ResultSet} object does <strong>not</strong> close the {@code Blob},185* {@code Clob} or {@code NClob} objects created by the {@code ResultSet}. {@code Blob},186* {@code Clob} or {@code NClob} objects remain valid for at least the duration of the187* transaction in which they are created, unless their {@code free} method is invoked.188*<p>189* When a {@code ResultSet} is closed, any {@code ResultSetMetaData}190* instances that were created by calling the {@code getMetaData}191* method remain accessible.192*193* <P><B>Note:</B> A {@code ResultSet} object194* is automatically closed by the195* {@code Statement} object that generated it when196* that {@code Statement} object is closed,197* re-executed, or is used to retrieve the next result from a198* sequence of multiple results.199*<p>200* Calling the method {@code close} on a {@code ResultSet}201* object that is already closed is a no-op.202*203*204* @throws SQLException if a database access error occurs205*/206void close() throws SQLException;207208/**209* Reports whether210* the last column read had a value of SQL {@code NULL}.211* Note that you must first call one of the getter methods212* on a column to try to read its value and then call213* the method {@code wasNull} to see if the value read was214* SQL {@code NULL}.215*216* @return {@code true} if the last column value read was SQL217* {@code NULL} and {@code false} otherwise218* @throws SQLException if a database access error occurs or this method is219* called on a closed result set220*/221boolean wasNull() throws SQLException;222223// Methods for accessing results by column index224225/**226* Retrieves the value of the designated column in the current row227* of this {@code ResultSet} object as228* a {@code String} in the Java programming language.229*230* @param columnIndex the first column is 1, the second is 2, ...231* @return the column value; if the value is SQL {@code NULL}, the232* value returned is {@code null}233* @throws SQLException if the columnIndex is not valid;234* if a database access error occurs or this method is235* called on a closed result set236*/237String getString(int columnIndex) throws SQLException;238239/**240* Retrieves the value of the designated column in the current row241* of this {@code ResultSet} object as242* a {@code boolean} in the Java programming language.243*244* <P>If the designated column has a datatype of CHAR or VARCHAR245* and contains a "0" or has a datatype of BIT, TINYINT, SMALLINT, INTEGER or BIGINT246* and contains a 0, a value of {@code false} is returned. If the designated column has a datatype247* of CHAR or VARCHAR248* and contains a "1" or has a datatype of BIT, TINYINT, SMALLINT, INTEGER or BIGINT249* and contains a 1, a value of {@code true} is returned.250*251* @param columnIndex the first column is 1, the second is 2, ...252* @return the column value; if the value is SQL {@code NULL}, the253* value returned is {@code false}254* @throws SQLException if the columnIndex is not valid;255* if a database access error occurs or this method is256* called on a closed result set257*/258boolean getBoolean(int columnIndex) throws SQLException;259260/**261* Retrieves the value of the designated column in the current row262* of this {@code ResultSet} object as263* a {@code byte} in the Java programming language.264*265* @param columnIndex the first column is 1, the second is 2, ...266* @return the column value; if the value is SQL {@code NULL}, the267* value returned is {@code 0}268* @throws SQLException if the columnIndex is not valid;269* if a database access error occurs or this method is270* called on a closed result set271*/272byte getByte(int columnIndex) throws SQLException;273274/**275* Retrieves the value of the designated column in the current row276* of this {@code ResultSet} object as277* a {@code short} in the Java programming language.278*279* @param columnIndex the first column is 1, the second is 2, ...280* @return the column value; if the value is SQL {@code NULL}, the281* value returned is {@code 0}282* @throws SQLException if the columnIndex is not valid;283* if a database access error occurs or this method is284* called on a closed result set285*/286short getShort(int columnIndex) throws SQLException;287288/**289* Retrieves the value of the designated column in the current row290* of this {@code ResultSet} object as291* an {@code int} in the Java programming language.292*293* @param columnIndex the first column is 1, the second is 2, ...294* @return the column value; if the value is SQL {@code NULL}, the295* value returned is {@code 0}296* @throws SQLException if the columnIndex is not valid;297* if a database access error occurs or this method is298* called on a closed result set299*/300int getInt(int columnIndex) throws SQLException;301302/**303* Retrieves the value of the designated column in the current row304* of this {@code ResultSet} object as305* a {@code long} in the Java programming language.306*307* @param columnIndex the first column is 1, the second is 2, ...308* @return the column value; if the value is SQL {@code NULL}, the309* value returned is {@code 0}310* @throws SQLException if the columnIndex is not valid;311* if a database access error occurs or this method is312* called on a closed result set313*/314long getLong(int columnIndex) throws SQLException;315316/**317* Retrieves the value of the designated column in the current row318* of this {@code ResultSet} object as319* a {@code float} in the Java programming language.320*321* @param columnIndex the first column is 1, the second is 2, ...322* @return the column value; if the value is SQL {@code NULL}, the323* value returned is {@code 0}324* @throws SQLException if the columnIndex is not valid;325* if a database access error occurs or this method is326* called on a closed result set327*/328float getFloat(int columnIndex) throws SQLException;329330/**331* Retrieves the value of the designated column in the current row332* of this {@code ResultSet} object as333* a {@code double} in the Java programming language.334*335* @param columnIndex the first column is 1, the second is 2, ...336* @return the column value; if the value is SQL {@code NULL}, the337* value returned is {@code 0}338* @throws SQLException if the columnIndex is not valid;339* if a database access error occurs or this method is340* called on a closed result set341*/342double getDouble(int columnIndex) throws SQLException;343344/**345* Retrieves the value of the designated column in the current row346* of this {@code ResultSet} object as347* a {@code java.sql.BigDecimal} in the Java programming language.348*349* @param columnIndex the first column is 1, the second is 2, ...350* @param scale the number of digits to the right of the decimal point351* @return the column value; if the value is SQL {@code NULL}, the352* value returned is {@code null}353* @throws SQLException if the columnIndex is not valid;354* if a database access error occurs or this method is355* called on a closed result set356* @throws SQLFeatureNotSupportedException if the JDBC driver does not support357* this method358* @deprecated Use {@code getBigDecimal(int columnIndex)}359* or {@code getBigDecimal(String columnLabel)}360*/361@Deprecated(since="1.2")362BigDecimal getBigDecimal(int columnIndex, int scale) throws SQLException;363364/**365* Retrieves the value of the designated column in the current row366* of this {@code ResultSet} object as367* a {@code byte} array in the Java programming language.368* The bytes represent the raw values returned by the driver.369*370* @param columnIndex the first column is 1, the second is 2, ...371* @return the column value; if the value is SQL {@code NULL}, the372* value returned is {@code null}373* @throws SQLException if the columnIndex is not valid;374* if a database access error occurs or this method is375* called on a closed result set376*/377byte[] getBytes(int columnIndex) throws SQLException;378379/**380* Retrieves the value of the designated column in the current row381* of this {@code ResultSet} object as382* a {@code java.sql.Date} object in the Java programming language.383*384* @param columnIndex the first column is 1, the second is 2, ...385* @return the column value; if the value is SQL {@code NULL}, the386* value returned is {@code null}387* @throws SQLException if the columnIndex is not valid;388* if a database access error occurs or this method is389* called on a closed result set390*/391java.sql.Date getDate(int columnIndex) throws SQLException;392393/**394* Retrieves the value of the designated column in the current row395* of this {@code ResultSet} object as396* a {@code java.sql.Time} object in the Java programming language.397*398* @param columnIndex the first column is 1, the second is 2, ...399* @return the column value; if the value is SQL {@code NULL}, the400* value returned is {@code null}401* @throws SQLException if the columnIndex is not valid;402* if a database access error occurs or this method is403* called on a closed result set404*/405java.sql.Time getTime(int columnIndex) throws SQLException;406407/**408* Retrieves the value of the designated column in the current row409* of this {@code ResultSet} object as410* a {@code java.sql.Timestamp} object in the Java programming language.411*412* @param columnIndex the first column is 1, the second is 2, ...413* @return the column value; if the value is SQL {@code NULL}, the414* value returned is {@code null}415* @throws SQLException if the columnIndex is not valid;416* if a database access error occurs or this method is417* called on a closed result set418*/419java.sql.Timestamp getTimestamp(int columnIndex) throws SQLException;420421/**422* Retrieves the value of the designated column in the current row423* of this {@code ResultSet} object as424* a stream of ASCII characters. The value can then be read in chunks from the425* stream. This method is particularly426* suitable for retrieving large {@code LONGVARCHAR} values.427* The JDBC driver will428* do any necessary conversion from the database format into ASCII.429*430* <P><B>Note:</B> All the data in the returned stream must be431* read prior to getting the value of any other column. The next432* call to a getter method implicitly closes the stream. Also, a433* stream may return {@code 0} when the method434* {@code InputStream.available}435* is called whether there is data available or not.436*437* @param columnIndex the first column is 1, the second is 2, ...438* @return a Java input stream that delivers the database column value439* as a stream of one-byte ASCII characters;440* if the value is SQL {@code NULL}, the441* value returned is {@code null}442* @throws SQLException if the columnIndex is not valid;443* if a database access error occurs or this method is444* called on a closed result set445*/446java.io.InputStream getAsciiStream(int columnIndex) throws SQLException;447448/**449* Retrieves the value of the designated column in the current row450* of this {@code ResultSet} object as451* as a stream of two-byte 3 characters. The first byte is452* the high byte; the second byte is the low byte.453*454* The value can then be read in chunks from the455* stream. This method is particularly456* suitable for retrieving large {@code LONGVARCHAR}values. The457* JDBC driver will do any necessary conversion from the database458* format into Unicode.459*460* <P><B>Note:</B> All the data in the returned stream must be461* read prior to getting the value of any other column. The next462* call to a getter method implicitly closes the stream.463* Also, a stream may return {@code 0} when the method464* {@code InputStream.available}465* is called, whether there is data available or not.466*467* @param columnIndex the first column is 1, the second is 2, ...468* @return a Java input stream that delivers the database column value469* as a stream of two-byte Unicode characters;470* if the value is SQL {@code NULL}, the value returned is471* {@code null}472*473* @throws SQLException if the columnIndex is not valid;474* if a database access error occurs or this method is475* called on a closed result set476* @throws SQLFeatureNotSupportedException if the JDBC driver does not support477* this method478* @deprecated use {@code getCharacterStream} in place of479* {@code getUnicodeStream}480*/481@Deprecated(since="1.2")482java.io.InputStream getUnicodeStream(int columnIndex) throws SQLException;483484/**485* Retrieves the value of the designated column in the current row486* of this {@code ResultSet} object as a stream of487* uninterpreted bytes. The value can then be read in chunks from the488* stream. This method is particularly489* suitable for retrieving large {@code LONGVARBINARY} values.490*491* <P><B>Note:</B> All the data in the returned stream must be492* read prior to getting the value of any other column. The next493* call to a getter method implicitly closes the stream. Also, a494* stream may return {@code 0} when the method495* {@code InputStream.available}496* is called whether there is data available or not.497*498* @param columnIndex the first column is 1, the second is 2, ...499* @return a Java input stream that delivers the database column value500* as a stream of uninterpreted bytes;501* if the value is SQL {@code NULL}, the value returned is502* {@code null}503* @throws SQLException if the columnIndex is not valid;504* if a database access error occurs or this method is505* called on a closed result set506*/507java.io.InputStream getBinaryStream(int columnIndex)508throws SQLException;509510511// Methods for accessing results by column label512513/**514* Retrieves the value of the designated column in the current row515* of this {@code ResultSet} object as516* a {@code String} in the Java programming language.517*518* @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 column519* @return the column value; if the value is SQL {@code NULL}, the520* value returned is {@code null}521* @throws SQLException if the columnLabel is not valid;522* if a database access error occurs or this method is523* called on a closed result set524*/525String getString(String columnLabel) throws SQLException;526527/**528* Retrieves the value of the designated column in the current row529* of this {@code ResultSet} object as530* a {@code boolean} in the Java programming language.531*532* <P>If the designated column has a datatype of CHAR or VARCHAR533* and contains a "0" or has a datatype of BIT, TINYINT, SMALLINT, INTEGER or BIGINT534* and contains a 0, a value of {@code false} is returned. If the designated column has a datatype535* of CHAR or VARCHAR536* and contains a "1" or has a datatype of BIT, TINYINT, SMALLINT, INTEGER or BIGINT537* and contains a 1, a value of {@code true} is returned.538*539* @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 column540* @return the column value; if the value is SQL {@code NULL}, the541* value returned is {@code false}542* @throws SQLException if the columnLabel is not valid;543* if a database access error occurs or this method is544* called on a closed result set545*/546boolean getBoolean(String columnLabel) throws SQLException;547548/**549* Retrieves the value of the designated column in the current row550* of this {@code ResultSet} object as551* a {@code byte} in the Java programming language.552*553* @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 column554* @return the column value; if the value is SQL {@code NULL}, the555* value returned is {@code 0}556* @throws SQLException if the columnLabel is not valid;557* if a database access error occurs or this method is558* called on a closed result set559*/560byte getByte(String columnLabel) throws SQLException;561562/**563* Retrieves the value of the designated column in the current row564* of this {@code ResultSet} object as565* a {@code short} in the Java programming language.566*567* @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 column568* @return the column value; if the value is SQL {@code NULL}, the569* value returned is {@code 0}570* @throws SQLException if the columnLabel is not valid;571* if a database access error occurs or this method is572* called on a closed result set573*/574short getShort(String columnLabel) throws SQLException;575576/**577* Retrieves the value of the designated column in the current row578* of this {@code ResultSet} object as579* an {@code int} in the Java programming language.580*581* @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 column582* @return the column value; if the value is SQL {@code NULL}, the583* value returned is {@code 0}584* @throws SQLException if the columnLabel is not valid;585* if a database access error occurs or this method is586* called on a closed result set587*/588int getInt(String columnLabel) throws SQLException;589590/**591* Retrieves the value of the designated column in the current row592* of this {@code ResultSet} object as593* a {@code long} in the Java programming language.594*595* @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 column596* @return the column value; if the value is SQL {@code NULL}, the597* value returned is {@code 0}598* @throws SQLException if the columnLabel is not valid;599* if a database access error occurs or this method is600* called on a closed result set601*/602long getLong(String columnLabel) throws SQLException;603604/**605* Retrieves the value of the designated column in the current row606* of this {@code ResultSet} object as607* a {@code float} in the Java programming language.608*609* @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 column610* @return the column value; if the value is SQL {@code NULL}, the611* value returned is {@code 0}612* @throws SQLException if the columnLabel is not valid;613* if a database access error occurs or this method is614* called on a closed result set615*/616float getFloat(String columnLabel) throws SQLException;617618/**619* Retrieves the value of the designated column in the current row620* of this {@code ResultSet} object as621* a {@code double} in the Java programming language.622*623* @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 column624* @return the column value; if the value is SQL {@code NULL}, the625* value returned is {@code 0}626* @throws SQLException if the columnLabel is not valid;627* if a database access error occurs or this method is628* called on a closed result set629*/630double getDouble(String columnLabel) throws SQLException;631632/**633* Retrieves the value of the designated column in the current row634* of this {@code ResultSet} object as635* a {@code java.math.BigDecimal} in the Java programming language.636*637* @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 column638* @param scale the number of digits to the right of the decimal point639* @return the column value; if the value is SQL {@code NULL}, the640* value returned is {@code null}641* @throws SQLException if the columnLabel is not valid;642* if a database access error occurs or this method is643* called on a closed result set644* @throws SQLFeatureNotSupportedException if the JDBC driver does not support645* this method646* @deprecated Use {@code getBigDecimal(int columnIndex)}647* or {@code getBigDecimal(String columnLabel)}648*/649@Deprecated(since="1.2")650BigDecimal getBigDecimal(String columnLabel, int scale) throws SQLException;651652/**653* Retrieves the value of the designated column in the current row654* of this {@code ResultSet} object as655* a {@code byte} array in the Java programming language.656* The bytes represent the raw values returned by the driver.657*658* @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 column659* @return the column value; if the value is SQL {@code NULL}, the660* value returned is {@code null}661* @throws SQLException if the columnLabel is not valid;662* if a database access error occurs or this method is663* called on a closed result set664*/665byte[] getBytes(String columnLabel) throws SQLException;666667/**668* Retrieves the value of the designated column in the current row669* of this {@code ResultSet} object as670* a {@code java.sql.Date} object in the Java programming language.671*672* @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 column673* @return the column value; if the value is SQL {@code NULL}, the674* value returned is {@code null}675* @throws SQLException if the columnLabel is not valid;676* if a database access error occurs or this method is677* called on a closed result set678*/679java.sql.Date getDate(String columnLabel) throws SQLException;680681/**682* Retrieves the value of the designated column in the current row683* of this {@code ResultSet} object as684* a {@code java.sql.Time} object in the Java programming language.685*686* @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 column687* @return the column value;688* if the value is SQL {@code NULL},689* the value returned is {@code null}690* @throws SQLException if the columnLabel is not valid;691* if a database access error occurs or this method is692* called on a closed result set693*/694java.sql.Time getTime(String columnLabel) throws SQLException;695696/**697* Retrieves the value of the designated column in the current row698* of this {@code ResultSet} object as699* a {@code java.sql.Timestamp} object in the Java programming language.700*701* @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 column702* @return the column value; if the value is SQL {@code NULL}, the703* value returned is {@code null}704* @throws SQLException if the columnLabel is not valid;705* if a database access error occurs or this method is706* called on a closed result set707*/708java.sql.Timestamp getTimestamp(String columnLabel) throws SQLException;709710/**711* Retrieves the value of the designated column in the current row712* of this {@code ResultSet} object as a stream of713* ASCII characters. The value can then be read in chunks from the714* stream. This method is particularly715* suitable for retrieving large {@code LONGVARCHAR} values.716* The JDBC driver will717* do any necessary conversion from the database format into ASCII.718*719* <P><B>Note:</B> All the data in the returned stream must be720* read prior to getting the value of any other column. The next721* call to a getter method implicitly closes the stream. Also, a722* stream may return {@code 0} when the method {@code available}723* is called whether there is data available or not.724*725* @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 column726* @return a Java input stream that delivers the database column value727* as a stream of one-byte ASCII characters.728* If the value is SQL {@code NULL},729* the value returned is {@code null}.730* @throws SQLException if the columnLabel is not valid;731* if a database access error occurs or this method is732* called on a closed result set733*/734java.io.InputStream getAsciiStream(String columnLabel) throws SQLException;735736/**737* Retrieves the value of the designated column in the current row738* of this {@code ResultSet} object as a stream of two-byte739* Unicode characters. The first byte is the high byte; the second740* byte is the low byte.741*742* The value can then be read in chunks from the743* stream. This method is particularly744* suitable for retrieving large {@code LONGVARCHAR} values.745* The JDBC technology-enabled driver will746* do any necessary conversion from the database format into Unicode.747*748* <P><B>Note:</B> All the data in the returned stream must be749* read prior to getting the value of any other column. The next750* call to a getter method implicitly closes the stream.751* Also, a stream may return {@code 0} when the method752* {@code InputStream.available} is called, whether there753* is data available or not.754*755* @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 column756* @return a Java input stream that delivers the database column value757* as a stream of two-byte Unicode characters.758* If the value is SQL {@code NULL}, the value returned759* is {@code null}.760* @throws SQLException if the columnLabel is not valid;761* if a database access error occurs or this method is762* called on a closed result set763* @throws SQLFeatureNotSupportedException if the JDBC driver does not support764* this method765* @deprecated use {@code getCharacterStream} instead766*/767@Deprecated(since="1.2")768java.io.InputStream getUnicodeStream(String columnLabel) throws SQLException;769770/**771* Retrieves the value of the designated column in the current row772* of this {@code ResultSet} object as a stream of uninterpreted773* {@code byte}s.774* The value can then be read in chunks from the775* stream. This method is particularly776* suitable for retrieving large {@code LONGVARBINARY}777* values.778*779* <P><B>Note:</B> All the data in the returned stream must be780* read prior to getting the value of any other column. The next781* call to a getter method implicitly closes the stream. Also, a782* stream may return {@code 0} when the method {@code available}783* is called whether there is data available or not.784*785* @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 column786* @return a Java input stream that delivers the database column value787* as a stream of uninterpreted bytes;788* if the value is SQL {@code NULL}, the result is {@code null}789* @throws SQLException if the columnLabel is not valid;790* if a database access error occurs or this method is791* called on a closed result set792*/793java.io.InputStream getBinaryStream(String columnLabel)794throws SQLException;795796797// Advanced features:798799/**800* Retrieves the first warning reported by calls on this801* {@code ResultSet} object.802* Subsequent warnings on this {@code ResultSet} object803* will be chained to the {@code SQLWarning} object that804* this method returns.805*806* <P>The warning chain is automatically cleared each time a new807* row is read. This method may not be called on a {@code ResultSet}808* object that has been closed; doing so will cause an809* {@code SQLException} to be thrown.810* <P>811* <B>Note:</B> This warning chain only covers warnings caused812* by {@code ResultSet} methods. Any warning caused by813* {@code Statement} methods814* (such as reading OUT parameters) will be chained on the815* {@code Statement} object.816*817* @return the first {@code SQLWarning} object reported or818* {@code null} if there are none819* @throws SQLException if a database access error occurs or this method is820* called on a closed result set821*/822SQLWarning getWarnings() throws SQLException;823824/**825* Clears all warnings reported on this {@code ResultSet} object.826* After this method is called, the method {@code getWarnings}827* returns {@code null} until a new warning is828* reported for this {@code ResultSet} object.829*830* @throws SQLException if a database access error occurs or this method is831* called on a closed result set832*/833void clearWarnings() throws SQLException;834835/**836* Retrieves the name of the SQL cursor used by this {@code ResultSet}837* object.838*839* <P>In SQL, a result table is retrieved through a cursor that is840* named. The current row of a result set can be updated or deleted841* using a positioned update/delete statement that references the842* cursor name. To insure that the cursor has the proper isolation843* level to support update, the cursor's {@code SELECT} statement844* should be of the form {@code SELECT FOR UPDATE}. If845* {@code FOR UPDATE} is omitted, the positioned updates may fail.846*847* <P>The JDBC API supports this SQL feature by providing the name of the848* SQL cursor used by a {@code ResultSet} object.849* The current row of a {@code ResultSet} object850* is also the current row of this SQL cursor.851*852* @return the SQL name for this {@code ResultSet} object's cursor853* @throws SQLException if a database access error occurs or this method is called on a closed result set854* @throws SQLFeatureNotSupportedException if the JDBC driver does not support855* this method856*/857String getCursorName() throws SQLException;858859/**860* Retrieves the number, types and properties of861* this {@code ResultSet} object's columns.862*863* @return the description of this {@code ResultSet} object's columns864* @throws SQLException if a database access error occurs or this method is865* called on a closed result set866*/867ResultSetMetaData getMetaData() throws SQLException;868869/**870* <p>Gets the value of the designated column in the current row871* of this {@code ResultSet} object as872* an {@code Object} in the Java programming language.873*874* <p>This method will return the value of the given column as a875* Java object. The type of the Java object will be the default876* Java object type corresponding to the column's SQL type,877* following the mapping for built-in types specified in the JDBC878* specification. If the value is an SQL {@code NULL},879* the driver returns a Java {@code null}.880*881* <p>This method may also be used to read database-specific882* abstract data types.883*884* In the JDBC 2.0 API, the behavior of method885* {@code getObject} is extended to materialize886* data of SQL user-defined types.887* <p>888* If {@code Connection.getTypeMap} does not throw a889* {@code SQLFeatureNotSupportedException},890* then when a column contains a structured or distinct value,891* the behavior of this method is as892* if it were a call to: {@code getObject(columnIndex,893* this.getStatement().getConnection().getTypeMap())}.894*895* If {@code Connection.getTypeMap} does throw a896* {@code SQLFeatureNotSupportedException},897* then structured values are not supported, and distinct values898* are mapped to the default Java class as determined by the899* underlying SQL type of the DISTINCT type.900*901* @param columnIndex the first column is 1, the second is 2, ...902* @return a {@code java.lang.Object} holding the column value903* @throws SQLException if the columnIndex is not valid;904* if a database access error occurs or this method is905* called on a closed result set906*/907Object getObject(int columnIndex) throws SQLException;908909/**910* <p>Gets the value of the designated column in the current row911* of this {@code ResultSet} object as912* an {@code Object} in the Java programming language.913*914* <p>This method will return the value of the given column as a915* Java object. The type of the Java object will be the default916* Java object type corresponding to the column's SQL type,917* following the mapping for built-in types specified in the JDBC918* specification. If the value is an SQL {@code NULL},919* the driver returns a Java {@code null}.920* <P>921* This method may also be used to read database-specific922* abstract data types.923* <P>924* In the JDBC 2.0 API, the behavior of the method925* {@code getObject} is extended to materialize926* data of SQL user-defined types. When a column contains927* a structured or distinct value, the behavior of this method is as928* if it were a call to: {@code getObject(columnIndex,929* this.getStatement().getConnection().getTypeMap())}.930*931* @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 column932* @return a {@code java.lang.Object} holding the column value933* @throws SQLException if the columnLabel is not valid;934* if a database access error occurs or this method is935* called on a closed result set936*/937Object getObject(String columnLabel) throws SQLException;938939//----------------------------------------------------------------940941/**942* Maps the given {@code ResultSet} column label to its943* {@code ResultSet} column index.944*945* @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 column946* @return the column index of the given column name947* @throws SQLException if the {@code ResultSet} object948* does not contain a column labeled {@code columnLabel}, a database access error occurs949* or this method is called on a closed result set950*/951int findColumn(String columnLabel) throws SQLException;952953954//--------------------------JDBC 2.0-----------------------------------955956//---------------------------------------------------------------------957// Getters and Setters958//---------------------------------------------------------------------959960/**961* Retrieves the value of the designated column in the current row962* of this {@code ResultSet} object as a963* {@code java.io.Reader} object.964* @return a {@code java.io.Reader} object that contains the column965* value; if the value is SQL {@code NULL}, the value returned is966* {@code null} in the Java programming language.967* @param columnIndex the first column is 1, the second is 2, ...968* @throws SQLException if the columnIndex is not valid;969* if a database access error occurs or this method is970* called on a closed result set971* @since 1.2972*/973java.io.Reader getCharacterStream(int columnIndex) throws SQLException;974975/**976* Retrieves the value of the designated column in the current row977* of this {@code ResultSet} object as a978* {@code java.io.Reader} object.979*980* @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 column981* @return a {@code java.io.Reader} object that contains the column982* value; if the value is SQL {@code NULL}, the value returned is983* {@code null} in the Java programming language984* @throws SQLException if the columnLabel is not valid;985* if a database access error occurs or this method is986* called on a closed result set987* @since 1.2988*/989java.io.Reader getCharacterStream(String columnLabel) throws SQLException;990991/**992* Retrieves the value of the designated column in the current row993* of this {@code ResultSet} object as a994* {@code java.math.BigDecimal} with full precision.995*996* @param columnIndex the first column is 1, the second is 2, ...997* @return the column value (full precision);998* if the value is SQL {@code NULL}, the value returned is999* {@code null} in the Java programming language.1000* @throws SQLException if the columnIndex is not valid;1001* if a database access error occurs or this method is1002* called on a closed result set1003* @since 1.21004*/1005BigDecimal getBigDecimal(int columnIndex) throws SQLException;10061007/**1008* Retrieves the value of the designated column in the current row1009* of this {@code ResultSet} object as a1010* {@code java.math.BigDecimal} with full precision.1011*1012* @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 column1013* @return the column value (full precision);1014* if the value is SQL {@code NULL}, the value returned is1015* {@code null} in the Java programming language.1016* @throws SQLException if the columnLabel is not valid;1017* if a database access error occurs or this method is1018* called on a closed result set1019* @since 1.21020*1021*/1022BigDecimal getBigDecimal(String columnLabel) throws SQLException;10231024//---------------------------------------------------------------------1025// Traversal/Positioning1026//---------------------------------------------------------------------10271028/**1029* Retrieves whether the cursor is before the first row in1030* this {@code ResultSet} object.1031* <p>1032* <strong>Note:</strong>Support for the {@code isBeforeFirst} method1033* is optional for {@code ResultSet}s with a result1034* set type of {@code TYPE_FORWARD_ONLY}1035*1036* @return {@code true} if the cursor is before the first row;1037* {@code false} if the cursor is at any other position or the1038* result set contains no rows1039* @throws SQLException if a database access error occurs or this method is1040* called on a closed result set1041* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1042* this method1043* @since 1.21044*/1045boolean isBeforeFirst() throws SQLException;10461047/**1048* Retrieves whether the cursor is after the last row in1049* this {@code ResultSet} object.1050* <p>1051* <strong>Note:</strong>Support for the {@code isAfterLast} method1052* is optional for {@code ResultSet}s with a result1053* set type of {@code TYPE_FORWARD_ONLY}1054*1055* @return {@code true} if the cursor is after the last row;1056* {@code false} if the cursor is at any other position or the1057* result set contains no rows1058* @throws SQLException if a database access error occurs or this method is1059* called on a closed result set1060* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1061* this method1062* @since 1.21063*/1064boolean isAfterLast() throws SQLException;10651066/**1067* Retrieves whether the cursor is on the first row of1068* this {@code ResultSet} object.1069* <p>1070* <strong>Note:</strong>Support for the {@code isFirst} method1071* is optional for {@code ResultSet}s with a result1072* set type of {@code TYPE_FORWARD_ONLY}1073*1074* @return {@code true} if the cursor is on the first row;1075* {@code false} otherwise1076* @throws SQLException if a database access error occurs or this method is1077* called on a closed result set1078* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1079* this method1080* @since 1.21081*/1082boolean isFirst() throws SQLException;10831084/**1085* Retrieves whether the cursor is on the last row of1086* this {@code ResultSet} object.1087* <strong>Note:</strong> Calling the method {@code isLast} may be expensive1088* because the JDBC driver1089* might need to fetch ahead one row in order to determine1090* whether the current row is the last row in the result set.1091* <p>1092* <strong>Note:</strong> Support for the {@code isLast} method1093* is optional for {@code ResultSet}s with a result1094* set type of {@code TYPE_FORWARD_ONLY}1095* @return {@code true} if the cursor is on the last row;1096* {@code false} otherwise1097* @throws SQLException if a database access error occurs or this method is1098* called on a closed result set1099* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1100* this method1101* @since 1.21102*/1103boolean isLast() throws SQLException;11041105/**1106* Moves the cursor to the front of1107* this {@code ResultSet} object, just before the1108* first row. This method has no effect if the result set contains no rows.1109*1110* @throws SQLException if a database access error1111* occurs; this method is called on a closed result set or the1112* result set type is {@code TYPE_FORWARD_ONLY}1113* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1114* this method1115* @since 1.21116*/1117void beforeFirst() throws SQLException;11181119/**1120* Moves the cursor to the end of1121* this {@code ResultSet} object, just after the1122* last row. This method has no effect if the result set contains no rows.1123* @throws SQLException if a database access error1124* occurs; this method is called on a closed result set1125* or the result set type is {@code TYPE_FORWARD_ONLY}1126* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1127* this method1128* @since 1.21129*/1130void afterLast() throws SQLException;11311132/**1133* Moves the cursor to the first row in1134* this {@code ResultSet} object.1135*1136* @return {@code true} if the cursor is on a valid row;1137* {@code false} if there are no rows in the result set1138* @throws SQLException if a database access error1139* occurs; this method is called on a closed result set1140* or the result set type is {@code TYPE_FORWARD_ONLY}1141* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1142* this method1143* @since 1.21144*/1145boolean first() throws SQLException;11461147/**1148* Moves the cursor to the last row in1149* this {@code ResultSet} object.1150*1151* @return {@code true} if the cursor is on a valid row;1152* {@code false} if there are no rows in the result set1153* @throws SQLException if a database access error1154* occurs; this method is called on a closed result set1155* or the result set type is {@code TYPE_FORWARD_ONLY}1156* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1157* this method1158* @since 1.21159*/1160boolean last() throws SQLException;11611162/**1163* Retrieves the current row number. The first row is number 1, the1164* second number 2, and so on.1165* <p>1166* <strong>Note:</strong>Support for the {@code getRow} method1167* is optional for {@code ResultSet}s with a result1168* set type of {@code TYPE_FORWARD_ONLY}1169*1170* @return the current row number; {@code 0} if there is no current row1171* @throws SQLException if a database access error occurs1172* or this method is called on a closed result set1173* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1174* this method1175* @since 1.21176*/1177int getRow() throws SQLException;11781179/**1180* Moves the cursor to the given row number in1181* this {@code ResultSet} object.1182*1183* <p>If the row number is positive, the cursor moves to1184* the given row number with respect to the1185* beginning of the result set. The first row is row 1, the second1186* is row 2, and so on.1187*1188* <p>If the given row number is negative, the cursor moves to1189* an absolute row position with respect to1190* the end of the result set. For example, calling the method1191* {@code absolute(-1)} positions the1192* cursor on the last row; calling the method {@code absolute(-2)}1193* moves the cursor to the next-to-last row, and so on.1194*1195* <p>If the row number specified is zero, the cursor is moved to1196* before the first row.1197*1198* <p>An attempt to position the cursor beyond the first/last row in1199* the result set leaves the cursor before the first row or after1200* the last row.1201*1202* <p><B>Note:</B> Calling {@code absolute(1)} is the same1203* as calling {@code first()}. Calling {@code absolute(-1)}1204* is the same as calling {@code last()}.1205*1206* @param row the number of the row to which the cursor should move.1207* A value of zero indicates that the cursor will be positioned1208* before the first row; a positive number indicates the row number1209* counting from the beginning of the result set; a negative number1210* indicates the row number counting from the end of the result set1211* @return {@code true} if the cursor is moved to a position in this1212* {@code ResultSet} object;1213* {@code false} if the cursor is before the first row or after the1214* last row1215* @throws SQLException if a database access error1216* occurs; this method is called on a closed result set1217* or the result set type is {@code TYPE_FORWARD_ONLY}1218* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1219* this method1220* @since 1.21221*/1222boolean absolute( int row ) throws SQLException;12231224/**1225* Moves the cursor a relative number of rows, either positive or negative.1226* Attempting to move beyond the first/last row in the1227* result set positions the cursor before/after the1228* the first/last row. Calling {@code relative(0)} is valid, but does1229* not change the cursor position.1230*1231* <p>Note: Calling the method {@code relative(1)}1232* is identical to calling the method {@code next()} and1233* calling the method {@code relative(-1)} is identical1234* to calling the method {@code previous()}.1235*1236* @param rows an {@code int} specifying the number of rows to1237* move from the current row; a positive number moves the cursor1238* forward; a negative number moves the cursor backward1239* @return {@code true} if the cursor is on a row;1240* {@code false} otherwise1241* @throws SQLException if a database access error occurs; this method1242* is called on a closed result set or the result set type is1243* {@code TYPE_FORWARD_ONLY}1244* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1245* this method1246* @since 1.21247*/1248boolean relative( int rows ) throws SQLException;12491250/**1251* Moves the cursor to the previous row in this1252* {@code ResultSet} object.1253*<p>1254* When a call to the {@code previous} method returns {@code false},1255* the cursor is positioned before the first row. Any invocation of a1256* {@code ResultSet} method which requires a current row will result in a1257* {@code SQLException} being thrown.1258*<p>1259* If an input stream is open for the current row, a call to the method1260* {@code previous} will implicitly close it. A {@code ResultSet}1261* object's warning change is cleared when a new row is read.1262*1263* @return {@code true} if the cursor is now positioned on a valid row;1264* {@code false} if the cursor is positioned before the first row1265* @throws SQLException if a database access error1266* occurs; this method is called on a closed result set1267* or the result set type is {@code TYPE_FORWARD_ONLY}1268* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1269* this method1270* @since 1.21271*/1272boolean previous() throws SQLException;12731274//---------------------------------------------------------------------1275// Properties1276//---------------------------------------------------------------------12771278/**1279* The constant indicating that the rows in a result set will be1280* processed in a forward direction; first-to-last.1281* This constant is used by the method {@code setFetchDirection}1282* as a hint to the driver, which the driver may ignore.1283* @since 1.21284*/1285int FETCH_FORWARD = 1000;12861287/**1288* The constant indicating that the rows in a result set will be1289* processed in a reverse direction; last-to-first.1290* This constant is used by the method {@code setFetchDirection}1291* as a hint to the driver, which the driver may ignore.1292* @since 1.21293*/1294int FETCH_REVERSE = 1001;12951296/**1297* The constant indicating that the order in which rows in a1298* result set will be processed is unknown.1299* This constant is used by the method {@code setFetchDirection}1300* as a hint to the driver, which the driver may ignore.1301*/1302int FETCH_UNKNOWN = 1002;13031304/**1305* Gives a hint as to the direction in which the rows in this1306* {@code ResultSet} object will be processed.1307* The initial value is determined by the1308* {@code Statement} object1309* that produced this {@code ResultSet} object.1310* The fetch direction may be changed at any time.1311*1312* @param direction an {@code int} specifying the suggested1313* fetch direction; one of {@code ResultSet.FETCH_FORWARD},1314* {@code ResultSet.FETCH_REVERSE}, or1315* {@code ResultSet.FETCH_UNKNOWN}1316* @throws SQLException if a database access error occurs; this1317* method is called on a closed result set or1318* the result set type is {@code TYPE_FORWARD_ONLY} and the fetch1319* direction is not {@code FETCH_FORWARD}1320* @since 1.21321* @see Statement#setFetchDirection1322* @see #getFetchDirection1323*/1324void setFetchDirection(int direction) throws SQLException;13251326/**1327* Retrieves the fetch direction for this1328* {@code ResultSet} object.1329*1330* @return the current fetch direction for this {@code ResultSet} object1331* @throws SQLException if a database access error occurs1332* or this method is called on a closed result set1333* @since 1.21334* @see #setFetchDirection1335*/1336int getFetchDirection() throws SQLException;13371338/**1339* Gives the JDBC driver a hint as to the number of rows that should1340* be fetched from the database when more rows are needed for this1341* {@code ResultSet} object.1342* If the fetch size specified is zero, the JDBC driver1343* ignores the value and is free to make its own best guess as to what1344* the fetch size should be. The default value is set by the1345* {@code Statement} object1346* that created the result set. The fetch size may be changed at any time.1347*1348* @param rows the number of rows to fetch1349* @throws SQLException if a database access error occurs; this method1350* is called on a closed result set or the1351* condition {@code rows >= 0} is not satisfied1352* @since 1.21353* @see #getFetchSize1354*/1355void setFetchSize(int rows) throws SQLException;13561357/**1358* Retrieves the fetch size for this1359* {@code ResultSet} object.1360*1361* @return the current fetch size for this {@code ResultSet} object1362* @throws SQLException if a database access error occurs1363* or this method is called on a closed result set1364* @since 1.21365* @see #setFetchSize1366*/1367int getFetchSize() throws SQLException;13681369/**1370* The constant indicating the type for a {@code ResultSet} object1371* whose cursor may move only forward.1372* @since 1.21373*/1374int TYPE_FORWARD_ONLY = 1003;13751376/**1377* The constant indicating the type for a {@code ResultSet} object1378* that is scrollable but generally not sensitive to changes to the data1379* that underlies the {@code ResultSet}.1380* @since 1.21381*/1382int TYPE_SCROLL_INSENSITIVE = 1004;13831384/**1385* The constant indicating the type for a {@code ResultSet} object1386* that is scrollable and generally sensitive to changes to the data1387* that underlies the {@code ResultSet}.1388* @since 1.21389*/1390int TYPE_SCROLL_SENSITIVE = 1005;13911392/**1393* Retrieves the type of this {@code ResultSet} object.1394* The type is determined by the {@code Statement} object1395* that created the result set.1396*1397* @return {@code ResultSet.TYPE_FORWARD_ONLY},1398* {@code ResultSet.TYPE_SCROLL_INSENSITIVE},1399* or {@code ResultSet.TYPE_SCROLL_SENSITIVE}1400* @throws SQLException if a database access error occurs1401* or this method is called on a closed result set1402* @since 1.21403*/1404int getType() throws SQLException;14051406/**1407* The constant indicating the concurrency mode for a1408* {@code ResultSet} object that may NOT be updated.1409* @since 1.21410*/1411int CONCUR_READ_ONLY = 1007;14121413/**1414* The constant indicating the concurrency mode for a1415* {@code ResultSet} object that may be updated.1416* @since 1.21417*/1418int CONCUR_UPDATABLE = 1008;14191420/**1421* Retrieves the concurrency mode of this {@code ResultSet} object.1422* The concurrency used is determined by the1423* {@code Statement} object that created the result set.1424*1425* @return the concurrency type, either1426* {@code ResultSet.CONCUR_READ_ONLY}1427* or {@code ResultSet.CONCUR_UPDATABLE}1428* @throws SQLException if a database access error occurs1429* or this method is called on a closed result set1430* @since 1.21431*/1432int getConcurrency() throws SQLException;14331434//---------------------------------------------------------------------1435// Updates1436//---------------------------------------------------------------------14371438/**1439* Retrieves whether the current row has been updated. The value returned1440* depends on whether or not the result set can detect updates.1441* <p>1442* <strong>Note:</strong> Support for the {@code rowUpdated} method is optional with a result set1443* concurrency of {@code CONCUR_READ_ONLY}1444* @return {@code true} if the current row is detected to1445* have been visibly updated by the owner or another; {@code false} otherwise1446* @throws SQLException if a database access error occurs1447* or this method is called on a closed result set1448* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1449* this method1450* @see DatabaseMetaData#updatesAreDetected1451* @since 1.21452*/1453boolean rowUpdated() throws SQLException;14541455/**1456* Retrieves whether the current row has had an insertion.1457* The value returned depends on whether or not this1458* {@code ResultSet} object can detect visible inserts.1459* <p>1460* <strong>Note:</strong> Support for the {@code rowInserted} method is optional with a result set1461* concurrency of {@code CONCUR_READ_ONLY}1462* @return {@code true} if the current row is detected to1463* have been inserted; {@code false} otherwise1464* @throws SQLException if a database access error occurs1465* or this method is called on a closed result set1466* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1467* this method1468*1469* @see DatabaseMetaData#insertsAreDetected1470* @since 1.21471*/1472boolean rowInserted() throws SQLException;14731474/**1475* Retrieves whether a row has been deleted. A deleted row may leave1476* a visible "hole" in a result set. This method can be used to1477* detect holes in a result set. The value returned depends on whether1478* or not this {@code ResultSet} object can detect deletions.1479* <p>1480* <strong>Note:</strong> Support for the {@code rowDeleted} method is optional with a result set1481* concurrency of {@code CONCUR_READ_ONLY}1482* @return {@code true} if the current row is detected to1483* have been deleted by the owner or another; {@code false} otherwise1484* @throws SQLException if a database access error occurs1485* or this method is called on a closed result set1486* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1487* this method1488*1489* @see DatabaseMetaData#deletesAreDetected1490* @since 1.21491*/1492boolean rowDeleted() throws SQLException;14931494/**1495* Updates the designated column with a {@code null} value.1496*1497* The updater methods are used to update column values in the1498* current row or the insert row. The updater methods do not1499* update the underlying database; instead the {@code updateRow}1500* or {@code insertRow} methods are called to update the database.1501*1502* @param columnIndex the first column is 1, the second is 2, ...1503* @throws SQLException if the columnIndex is not valid;1504* if a database access error occurs;1505* the result set concurrency is {@code CONCUR_READ_ONLY}1506* or this method is called on a closed result set1507* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1508* this method1509* @since 1.21510*/1511void updateNull(int columnIndex) throws SQLException;15121513/**1514* Updates the designated column with a {@code boolean} value.1515* The updater methods are used to update column values in the1516* current row or the insert row. The updater methods do not1517* update the underlying database; instead the {@code updateRow} or1518* {@code insertRow} methods are called to update the database.1519*1520* @param columnIndex the first column is 1, the second is 2, ...1521* @param x the new column value1522* @throws SQLException if the columnIndex is not valid;1523* if a database access error occurs;1524* the result set concurrency is {@code CONCUR_READ_ONLY}1525* or this method is called on a closed result set1526* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1527* this method1528* @since 1.21529*/1530void updateBoolean(int columnIndex, boolean x) throws SQLException;15311532/**1533* Updates the designated column with a {@code byte} value.1534* The updater methods are used to update column values in the1535* current row or the insert row. The updater methods do not1536* update the underlying database; instead the {@code updateRow} or1537* {@code insertRow} methods are called to update the database.1538*1539*1540* @param columnIndex the first column is 1, the second is 2, ...1541* @param x the new column value1542* @throws SQLException if the columnIndex is not valid;1543* if a database access error occurs;1544* the result set concurrency is {@code CONCUR_READ_ONLY}1545* or this method is called on a closed result set1546* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1547* this method1548* @since 1.21549*/1550void updateByte(int columnIndex, byte x) throws SQLException;15511552/**1553* Updates the designated column with a {@code short} value.1554* The updater methods are used to update column values in the1555* current row or the insert row. The updater methods do not1556* update the underlying database; instead the {@code updateRow} or1557* {@code insertRow} methods are called to update the database.1558*1559* @param columnIndex the first column is 1, the second is 2, ...1560* @param x the new column value1561* @throws SQLException if the columnIndex is not valid;1562* if a database access error occurs;1563* the result set concurrency is {@code CONCUR_READ_ONLY}1564* or this method is called on a closed result set1565* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1566* this method1567* @since 1.21568*/1569void updateShort(int columnIndex, short x) throws SQLException;15701571/**1572* Updates the designated column with an {@code int} value.1573* The updater methods are used to update column values in the1574* current row or the insert row. The updater methods do not1575* update the underlying database; instead the {@code updateRow} or1576* {@code insertRow} methods are called to update the database.1577*1578* @param columnIndex the first column is 1, the second is 2, ...1579* @param x the new column value1580* @throws SQLException if the columnIndex is not valid;1581* if a database access error occurs;1582* the result set concurrency is {@code CONCUR_READ_ONLY}1583* or this method is called on a closed result set1584* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1585* this method1586* @since 1.21587*/1588void updateInt(int columnIndex, int x) throws SQLException;15891590/**1591* Updates the designated column with a {@code long} value.1592* The updater methods are used to update column values in the1593* current row or the insert row. The updater methods do not1594* update the underlying database; instead the {@code updateRow} or1595* {@code insertRow} methods are called to update the database.1596*1597* @param columnIndex the first column is 1, the second is 2, ...1598* @param x the new column value1599* @throws SQLException if the columnIndex is not valid;1600* if a database access error occurs;1601* the result set concurrency is {@code CONCUR_READ_ONLY}1602* or this method is called on a closed result set1603* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1604* this method1605* @since 1.21606*/1607void updateLong(int columnIndex, long x) throws SQLException;16081609/**1610* Updates the designated column with a {@code float} value.1611* The updater methods are used to update column values in the1612* current row or the insert row. The updater methods do not1613* update the underlying database; instead the {@code updateRow} or1614* {@code insertRow} methods are called to update the database.1615*1616* @param columnIndex the first column is 1, the second is 2, ...1617* @param x the new column value1618* @throws SQLException if the columnIndex is not valid;1619* if a database access error occurs;1620* the result set concurrency is {@code CONCUR_READ_ONLY}1621* or this method is called on a closed result set1622* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1623* this method1624* @since 1.21625*/1626void updateFloat(int columnIndex, float x) throws SQLException;16271628/**1629* Updates the designated column with a {@code double} value.1630* The updater methods are used to update column values in the1631* current row or the insert row. The updater methods do not1632* update the underlying database; instead the {@code updateRow} or1633* {@code insertRow} methods are called to update the database.1634*1635* @param columnIndex the first column is 1, the second is 2, ...1636* @param x the new column value1637* @throws SQLException if the columnIndex is not valid;1638* if a database access error occurs;1639* the result set concurrency is {@code CONCUR_READ_ONLY}1640* or this method is called on a closed result set1641* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1642* this method1643* @since 1.21644*/1645void updateDouble(int columnIndex, double x) throws SQLException;16461647/**1648* Updates the designated column with a {@code java.math.BigDecimal}1649* value.1650* The updater methods are used to update column values in the1651* current row or the insert row. The updater methods do not1652* update the underlying database; instead the {@code updateRow} or1653* {@code insertRow} methods are called to update the database.1654*1655* @param columnIndex the first column is 1, the second is 2, ...1656* @param x the new column value1657* @throws SQLException if the columnIndex is not valid;1658* if a database access error occurs;1659* the result set concurrency is {@code CONCUR_READ_ONLY}1660* or this method is called on a closed result set1661* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1662* this method1663* @since 1.21664*/1665void updateBigDecimal(int columnIndex, BigDecimal x) throws SQLException;16661667/**1668* Updates the designated column with a {@code String} value.1669* The updater methods are used to update column values in the1670* current row or the insert row. The updater methods do not1671* update the underlying database; instead the {@code updateRow} or1672* {@code insertRow} methods are called to update the database.1673*1674* @param columnIndex the first column is 1, the second is 2, ...1675* @param x the new column value1676* @throws SQLException if the columnIndex is not valid;1677* if a database access error occurs;1678* the result set concurrency is {@code CONCUR_READ_ONLY}1679* or this method is called on a closed result set1680* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1681* this method1682* @since 1.21683*/1684void updateString(int columnIndex, String x) throws SQLException;16851686/**1687* Updates the designated column with a {@code byte} array value.1688* The updater methods are used to update column values in the1689* current row or the insert row. The updater methods do not1690* update the underlying database; instead the {@code updateRow} or1691* {@code insertRow} methods are called to update the database.1692*1693* @param columnIndex the first column is 1, the second is 2, ...1694* @param x the new column value1695* @throws SQLException if the columnIndex is not valid;1696* if a database access error occurs;1697* the result set concurrency is {@code CONCUR_READ_ONLY}1698* or this method is called on a closed result set1699* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1700* this method1701* @since 1.21702*/1703void updateBytes(int columnIndex, byte x[]) throws SQLException;17041705/**1706* Updates the designated column with a {@code java.sql.Date} value.1707* The updater methods are used to update column values in the1708* current row or the insert row. The updater methods do not1709* update the underlying database; instead the {@code updateRow} or1710* {@code insertRow} methods are called to update the database.1711*1712* @param columnIndex the first column is 1, the second is 2, ...1713* @param x the new column value1714* @throws SQLException if the columnIndex is not valid;1715* if a database access error occurs;1716* the result set concurrency is {@code CONCUR_READ_ONLY}1717* or this method is called on a closed result set1718* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1719* this method1720* @since 1.21721*/1722void updateDate(int columnIndex, java.sql.Date x) throws SQLException;17231724/**1725* Updates the designated column with a {@code java.sql.Time} value.1726* The updater methods are used to update column values in the1727* current row or the insert row. The updater methods do not1728* update the underlying database; instead the {@code updateRow} or1729* {@code insertRow} methods are called to update the database.1730*1731* @param columnIndex the first column is 1, the second is 2, ...1732* @param x the new column value1733* @throws SQLException if the columnIndex is not valid;1734* if a database access error occurs;1735* the result set concurrency is {@code CONCUR_READ_ONLY}1736* or this method is called on a closed result set1737* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1738* this method1739* @since 1.21740*/1741void updateTime(int columnIndex, java.sql.Time x) throws SQLException;17421743/**1744* Updates the designated column with a {@code java.sql.Timestamp}1745* value.1746* The updater methods are used to update column values in the1747* current row or the insert row. The updater methods do not1748* update the underlying database; instead the {@code updateRow} or1749* {@code insertRow} methods are called to update the database.1750*1751* @param columnIndex the first column is 1, the second is 2, ...1752* @param x the new column value1753* @throws SQLException if the columnIndex is not valid;1754* if a database access error occurs;1755* the result set concurrency is {@code CONCUR_READ_ONLY}1756* or this method is called on a closed result set1757* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1758* this method1759* @since 1.21760*/1761void updateTimestamp(int columnIndex, java.sql.Timestamp x)1762throws SQLException;17631764/**1765* Updates the designated column with an ascii stream value, which will have1766* the specified number of bytes.1767* The updater methods are used to update column values in the1768* current row or the insert row. The updater methods do not1769* update the underlying database; instead the {@code updateRow} or1770* {@code insertRow} methods are called to update the database.1771*1772* @param columnIndex the first column is 1, the second is 2, ...1773* @param x the new column value1774* @param length the length of the stream1775* @throws SQLException if the columnIndex is not valid;1776* if a database access error occurs;1777* the result set concurrency is {@code CONCUR_READ_ONLY}1778* or this method is called on a closed result set1779* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1780* this method1781* @since 1.21782*/1783void updateAsciiStream(int columnIndex,1784java.io.InputStream x,1785int length) throws SQLException;17861787/**1788* Updates the designated column with a binary stream value, which will have1789* the specified number of bytes.1790* The updater methods are used to update column values in the1791* current row or the insert row. The updater methods do not1792* update the underlying database; instead the {@code updateRow} or1793* {@code insertRow} methods are called to update the database.1794*1795* @param columnIndex the first column is 1, the second is 2, ...1796* @param x the new column value1797* @param length the length of the stream1798* @throws SQLException if the columnIndex is not valid;1799* if a database access error occurs;1800* the result set concurrency is {@code CONCUR_READ_ONLY}1801* or this method is called on a closed result set1802* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1803* this method1804* @since 1.21805*/1806void updateBinaryStream(int columnIndex,1807java.io.InputStream x,1808int length) throws SQLException;18091810/**1811* Updates the designated column with a character stream value, which will have1812* the specified number of bytes.1813* The updater methods are used to update column values in the1814* current row or the insert row. The updater methods do not1815* update the underlying database; instead the {@code updateRow} or1816* {@code insertRow} methods are called to update the database.1817*1818* @param columnIndex the first column is 1, the second is 2, ...1819* @param x the new column value1820* @param length the length of the stream1821* @throws SQLException if the columnIndex is not valid;1822* if a database access error occurs;1823* the result set concurrency is {@code CONCUR_READ_ONLY}1824* or this method is called on a closed result set1825* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1826* this method1827* @since 1.21828*/1829void updateCharacterStream(int columnIndex,1830java.io.Reader x,1831int length) throws SQLException;18321833/**1834* Updates the designated column with an {@code Object} value.1835*1836* The updater methods are used to update column values in the1837* current row or the insert row. The updater methods do not1838* update the underlying database; instead the {@code updateRow} or1839* {@code insertRow} methods are called to update the database.1840*<p>1841* If the second argument is an {@code InputStream} then the stream must contain1842* the number of bytes specified by scaleOrLength. If the second argument is a1843* {@code Reader} then the reader must contain the number of characters specified1844* by scaleOrLength. If these conditions are not true the driver will generate a1845* {@code SQLException} when the statement is executed.1846*1847* @param columnIndex the first column is 1, the second is 2, ...1848* @param x the new column value1849* @param scaleOrLength for an object of {@code java.math.BigDecimal} ,1850* this is the number of digits after the decimal point. For1851* Java Object types {@code InputStream} and {@code Reader},1852* this is the length1853* of the data in the stream or reader. For all other types,1854* this value will be ignored.1855* @throws SQLException if the columnIndex is not valid;1856* if a database access error occurs;1857* the result set concurrency is {@code CONCUR_READ_ONLY}1858* or this method is called on a closed result set1859* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1860* this method1861* @since 1.21862*/1863void updateObject(int columnIndex, Object x, int scaleOrLength)1864throws SQLException;18651866/**1867* Updates the designated column with an {@code Object} value.1868*1869* The updater methods are used to update column values in the1870* current row or the insert row. The updater methods do not1871* update the underlying database; instead the {@code updateRow} or1872* {@code insertRow} methods are called to update the database.1873*1874* @param columnIndex the first column is 1, the second is 2, ...1875* @param x the new column value1876* @throws SQLException if the columnIndex is not valid;1877* if a database access error occurs;1878* the result set concurrency is {@code CONCUR_READ_ONLY}1879* or this method is called on a closed result set1880* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1881* this method1882* @since 1.21883*/1884void updateObject(int columnIndex, Object x) throws SQLException;18851886/**1887* Updates the designated column with a {@code null} value.1888* The updater methods are used to update column values in the1889* current row or the insert row. The updater methods do not1890* update the underlying database; instead the {@code updateRow} or1891* {@code insertRow} methods are called to update the database.1892*1893* @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 column1894* @throws SQLException if the columnLabel is not valid;1895* if a database access error occurs;1896* the result set concurrency is {@code CONCUR_READ_ONLY}1897* or this method is called on a closed result set1898* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1899* this method1900* @since 1.21901*/1902void updateNull(String columnLabel) throws SQLException;19031904/**1905* Updates the designated column with a {@code boolean} value.1906* The updater methods are used to update column values in the1907* current row or the insert row. The updater methods do not1908* update the underlying database; instead the {@code updateRow} or1909* {@code insertRow} methods are called to update the database.1910*1911* @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 column1912* @param x the new column value1913* @throws SQLException if the columnLabel is not valid;1914* if a database access error occurs;1915* the result set concurrency is {@code CONCUR_READ_ONLY}1916* or this method is called on a closed result set1917* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1918* this method1919* @since 1.21920*/1921void updateBoolean(String columnLabel, boolean x) throws SQLException;19221923/**1924* Updates the designated column with a {@code byte} value.1925* The updater methods are used to update column values in the1926* current row or the insert row. The updater methods do not1927* update the underlying database; instead the {@code updateRow} or1928* {@code insertRow} methods are called to update the database.1929*1930* @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 column1931* @param x the new column value1932* @throws SQLException if the columnLabel is not valid;1933* if a database access error occurs;1934* the result set concurrency is {@code CONCUR_READ_ONLY}1935* or this method is called on a closed result set1936* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1937* this method1938* @since 1.21939*/1940void updateByte(String columnLabel, byte x) throws SQLException;19411942/**1943* Updates the designated column with a {@code short} value.1944* The updater methods are used to update column values in the1945* current row or the insert row. The updater methods do not1946* update the underlying database; instead the {@code updateRow} or1947* {@code insertRow} methods are called to update the database.1948*1949* @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 column1950* @param x the new column value1951* @throws SQLException if the columnLabel is not valid;1952* if a database access error occurs;1953* the result set concurrency is {@code CONCUR_READ_ONLY}1954* or this method is called on a closed result set1955* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1956* this method1957* @since 1.21958*/1959void updateShort(String columnLabel, short x) throws SQLException;19601961/**1962* Updates the designated column with an {@code int} value.1963* The updater methods are used to update column values in the1964* current row or the insert row. The updater methods do not1965* update the underlying database; instead the {@code updateRow} or1966* {@code insertRow} methods are called to update the database.1967*1968* @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 column1969* @param x the new column value1970* @throws SQLException if the columnLabel is not valid;1971* if a database access error occurs;1972* the result set concurrency is {@code CONCUR_READ_ONLY}1973* or this method is called on a closed result set1974* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1975* this method1976* @since 1.21977*/1978void updateInt(String columnLabel, int x) throws SQLException;19791980/**1981* Updates the designated column with a {@code long} value.1982* The updater methods are used to update column values in the1983* current row or the insert row. The updater methods do not1984* update the underlying database; instead the {@code updateRow} or1985* {@code insertRow} methods are called to update the database.1986*1987* @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 column1988* @param x the new column value1989* @throws SQLException if the columnLabel is not valid;1990* if a database access error occurs;1991* the result set concurrency is {@code CONCUR_READ_ONLY}1992* or this method is called on a closed result set1993* @throws SQLFeatureNotSupportedException if the JDBC driver does not support1994* this method1995* @since 1.21996*/1997void updateLong(String columnLabel, long x) throws SQLException;19981999/**2000* Updates the designated column with a {@code float} value.2001* The updater methods are used to update column values in the2002* current row or the insert row. The updater methods do not2003* update the underlying database; instead the {@code updateRow} or2004* {@code insertRow} methods are called to update the database.2005*2006* @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 column2007* @param x the new column value2008* @throws SQLException if the columnLabel is not valid;2009* if a database access error occurs;2010* the result set concurrency is {@code CONCUR_READ_ONLY}2011* or this method is called on a closed result set2012* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2013* this method2014* @since 1.22015*/2016void updateFloat(String columnLabel, float x) throws SQLException;20172018/**2019* Updates the designated column with a {@code double} value.2020* The updater methods are used to update column values in the2021* current row or the insert row. The updater methods do not2022* update the underlying database; instead the {@code updateRow} or2023* {@code insertRow} methods are called to update the database.2024*2025* @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 column2026* @param x the new column value2027* @throws SQLException if the columnLabel is not valid;2028* if a database access error occurs;2029* the result set concurrency is {@code CONCUR_READ_ONLY}2030* or this method is called on a closed result set2031* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2032* this method2033* @since 1.22034*/2035void updateDouble(String columnLabel, double x) throws SQLException;20362037/**2038* Updates the designated column with a {@code java.sql.BigDecimal}2039* value.2040* The updater methods are used to update column values in the2041* current row or the insert row. The updater methods do not2042* update the underlying database; instead the {@code updateRow} or2043* {@code insertRow} methods are called to update the database.2044*2045* @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 column2046* @param x the new column value2047* @throws SQLException if the columnLabel is not valid;2048* if a database access error occurs;2049* the result set concurrency is {@code CONCUR_READ_ONLY}2050* or this method is called on a closed result set2051* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2052* this method2053* @since 1.22054*/2055void updateBigDecimal(String columnLabel, BigDecimal x) throws SQLException;20562057/**2058* Updates the designated column with a {@code String} value.2059* The updater methods are used to update column values in the2060* current row or the insert row. The updater methods do not2061* update the underlying database; instead the {@code updateRow} or2062* {@code insertRow} methods are called to update the database.2063*2064* @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 column2065* @param x the new column value2066* @throws SQLException if the columnLabel is not valid;2067* if a database access error occurs;2068* the result set concurrency is {@code CONCUR_READ_ONLY}2069* or this method is called on a closed result set2070* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2071* this method2072* @since 1.22073*/2074void updateString(String columnLabel, String x) throws SQLException;20752076/**2077* Updates the designated column with a byte array value.2078*2079* The updater methods are used to update column values in the2080* current row or the insert row. The updater methods do not2081* update the underlying database; instead the {@code updateRow}2082* or {@code insertRow} methods are called to update the database.2083*2084* @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 column2085* @param x the new column value2086* @throws SQLException if the columnLabel is not valid;2087* if a database access error occurs;2088* the result set concurrency is {@code CONCUR_READ_ONLY}2089* or this method is called on a closed result set2090* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2091* this method2092* @since 1.22093*/2094void updateBytes(String columnLabel, byte x[]) throws SQLException;20952096/**2097* Updates the designated column with a {@code java.sql.Date} value.2098* The updater methods are used to update column values in the2099* current row or the insert row. The updater methods do not2100* update the underlying database; instead the {@code updateRow} or2101* {@code insertRow} methods are called to update the database.2102*2103* @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 column2104* @param x the new column value2105* @throws SQLException if the columnLabel is not valid;2106* if a database access error occurs;2107* the result set concurrency is {@code CONCUR_READ_ONLY}2108* or this method is called on a closed result set2109* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2110* this method2111* @since 1.22112*/2113void updateDate(String columnLabel, java.sql.Date x) throws SQLException;21142115/**2116* Updates the designated column with a {@code java.sql.Time} value.2117* The updater methods are used to update column values in the2118* current row or the insert row. The updater methods do not2119* update the underlying database; instead the {@code updateRow} or2120* {@code insertRow} methods are called to update the database.2121*2122* @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 column2123* @param x the new column value2124* @throws SQLException if the columnLabel is not valid;2125* if a database access error occurs;2126* the result set concurrency is {@code CONCUR_READ_ONLY}2127* or this method is called on a closed result set2128* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2129* this method2130* @since 1.22131*/2132void updateTime(String columnLabel, java.sql.Time x) throws SQLException;21332134/**2135* Updates the designated column with a {@code java.sql.Timestamp}2136* value.2137* The updater methods are used to update column values in the2138* current row or the insert row. The updater methods do not2139* update the underlying database; instead the {@code updateRow} or2140* {@code insertRow} methods are called to update the database.2141*2142* @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 column2143* @param x the new column value2144* @throws SQLException if the columnLabel is not valid;2145* if a database access error occurs;2146* the result set concurrency is {@code CONCUR_READ_ONLY}2147* or this method is called on a closed result set2148* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2149* this method2150* @since 1.22151*/2152void updateTimestamp(String columnLabel, java.sql.Timestamp x)2153throws SQLException;21542155/**2156* Updates the designated column with an ascii stream value, which will have2157* the specified number of bytes.2158* The updater methods are used to update column values in the2159* current row or the insert row. The updater methods do not2160* update the underlying database; instead the {@code updateRow} or2161* {@code insertRow} methods are called to update the database.2162*2163* @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 column2164* @param x the new column value2165* @param length the length of the stream2166* @throws SQLException if the columnLabel is not valid;2167* if a database access error occurs;2168* the result set concurrency is {@code CONCUR_READ_ONLY}2169* or this method is called on a closed result set2170* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2171* this method2172* @since 1.22173*/2174void updateAsciiStream(String columnLabel,2175java.io.InputStream x,2176int length) throws SQLException;21772178/**2179* Updates the designated column with a binary stream value, which will have2180* the specified number of bytes.2181* The updater methods are used to update column values in the2182* current row or the insert row. The updater methods do not2183* update the underlying database; instead the {@code updateRow} or2184* {@code insertRow} methods are called to update the database.2185*2186* @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 column2187* @param x the new column value2188* @param length the length of the stream2189* @throws SQLException if the columnLabel is not valid;2190* if a database access error occurs;2191* the result set concurrency is {@code CONCUR_READ_ONLY}2192* or this method is called on a closed result set2193* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2194* this method2195* @since 1.22196*/2197void updateBinaryStream(String columnLabel,2198java.io.InputStream x,2199int length) throws SQLException;22002201/**2202* Updates the designated column with a character stream value, which will have2203* the specified number of bytes.2204* The updater methods are used to update column values in the2205* current row or the insert row. The updater methods do not2206* update the underlying database; instead the {@code updateRow} or2207* {@code insertRow} methods are called to update the database.2208*2209* @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 column2210* @param reader the {@code java.io.Reader} object containing2211* the new column value2212* @param length the length of the stream2213* @throws SQLException if the columnLabel is not valid;2214* if a database access error occurs;2215* the result set concurrency is {@code CONCUR_READ_ONLY}2216* or this method is called on a closed result set2217* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2218* this method2219* @since 1.22220*/2221void updateCharacterStream(String columnLabel,2222java.io.Reader reader,2223int length) throws SQLException;22242225/**2226* Updates the designated column with an {@code Object} value.2227*2228* The updater methods are used to update column values in the2229* current row or the insert row. The updater methods do not2230* update the underlying database; instead the {@code updateRow} or2231* {@code insertRow} methods are called to update the database.2232*<p>2233* If the second argument is an {@code InputStream} then the stream must contain2234* the number of bytes specified by scaleOrLength. If the second argument is a2235* {@code Reader} then the reader must contain the number of characters specified2236* by scaleOrLength. If these conditions are not true the driver will generate a2237* {@code SQLException} when the statement is executed.2238*2239* @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 column2240* @param x the new column value2241* @param scaleOrLength for an object of {@code java.math.BigDecimal} ,2242* this is the number of digits after the decimal point. For2243* Java Object types {@code InputStream} and {@code Reader},2244* this is the length2245* of the data in the stream or reader. For all other types,2246* this value will be ignored.2247* @throws SQLException if the columnLabel is not valid;2248* if a database access error occurs;2249* the result set concurrency is {@code CONCUR_READ_ONLY}2250* or this method is called on a closed result set2251* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2252* this method2253* @since 1.22254*/2255void updateObject(String columnLabel, Object x, int scaleOrLength)2256throws SQLException;22572258/**2259* Updates the designated column with an {@code Object} value.2260*2261* The updater methods are used to update column values in the2262* current row or the insert row. The updater methods do not2263* update the underlying database; instead the {@code updateRow} or2264* {@code insertRow} methods are called to update the database.2265*2266* @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 column2267* @param x the new column value2268* @throws SQLException if the columnLabel is not valid;2269* if a database access error occurs;2270* the result set concurrency is {@code CONCUR_READ_ONLY}2271* or this method is called on a closed result set2272* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2273* this method2274* @since 1.22275*/2276void updateObject(String columnLabel, Object x) throws SQLException;22772278/**2279* Inserts the contents of the insert row into this2280* {@code ResultSet} object and into the database.2281* The cursor must be on the insert row when this method is called.2282*2283* @throws SQLException if a database access error occurs;2284* the result set concurrency is {@code CONCUR_READ_ONLY},2285* this method is called on a closed result set,2286* if this method is called when the cursor is not on the insert row,2287* or if not all of non-nullable columns in2288* the insert row have been given a non-null value2289* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2290* this method2291* @since 1.22292*/2293void insertRow() throws SQLException;22942295/**2296* Updates the underlying database with the new contents of the2297* current row of this {@code ResultSet} object.2298* This method cannot be called when the cursor is on the insert row.2299*2300* @throws SQLException if a database access error occurs;2301* the result set concurrency is {@code CONCUR_READ_ONLY};2302* this method is called on a closed result set or2303* if this method is called when the cursor is on the insert row2304* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2305* this method2306* @since 1.22307*/2308void updateRow() throws SQLException;23092310/**2311* Deletes the current row from this {@code ResultSet} object2312* and from the underlying database. This method cannot be called when2313* the cursor is on the insert row.2314*2315* @throws SQLException if a database access error occurs;2316* the result set concurrency is {@code CONCUR_READ_ONLY};2317* this method is called on a closed result set2318* or if this method is called when the cursor is on the insert row2319* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2320* this method2321* @since 1.22322*/2323void deleteRow() throws SQLException;23242325/**2326* Refreshes the current row with its most recent value in2327* the database. This method cannot be called when2328* the cursor is on the insert row.2329*2330* <P>The {@code refreshRow} method provides a way for an2331* application to2332* explicitly tell the JDBC driver to refetch a row(s) from the2333* database. An application may want to call {@code refreshRow} when2334* caching or prefetching is being done by the JDBC driver to2335* fetch the latest value of a row from the database. The JDBC driver2336* may actually refresh multiple rows at once if the fetch size is2337* greater than one.2338*2339* <P> All values are refetched subject to the transaction isolation2340* level and cursor sensitivity. If {@code refreshRow} is called after2341* calling an updater method, but before calling2342* the method {@code updateRow}, then the2343* updates made to the row are lost. Calling the method2344* {@code refreshRow} frequently will likely slow performance.2345*2346* @throws SQLException if a database access error2347* occurs; this method is called on a closed result set;2348* the result set type is {@code TYPE_FORWARD_ONLY} or if this2349* method is called when the cursor is on the insert row2350* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2351* this method or this method is not supported for the specified result2352* set type and result set concurrency.2353* @since 1.22354*/2355void refreshRow() throws SQLException;23562357/**2358* Cancels the updates made to the current row in this2359* {@code ResultSet} object.2360* This method may be called after calling an2361* updater method(s) and before calling2362* the method {@code updateRow} to roll back2363* the updates made to a row. If no updates have been made or2364* {@code updateRow} has already been called, this method has no2365* effect.2366*2367* @throws SQLException if a database access error2368* occurs; this method is called on a closed result set;2369* the result set concurrency is {@code CONCUR_READ_ONLY}2370* or if this method is called when the cursor is2371* on the insert row2372* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2373* this method2374* @since 1.22375*/2376void cancelRowUpdates() throws SQLException;23772378/**2379* Moves the cursor to the insert row. The current cursor position is2380* remembered while the cursor is positioned on the insert row.2381*2382* The insert row is a special row associated with an updatable2383* result set. It is essentially a buffer where a new row may2384* be constructed by calling the updater methods prior to2385* inserting the row into the result set.2386*2387* Only the updater, getter,2388* and {@code insertRow} methods may be2389* called when the cursor is on the insert row. All of the columns in2390* a result set must be given a value each time this method is2391* called before calling {@code insertRow}.2392* An updater method must be called before a2393* getter method can be called on a column value.2394*2395* @throws SQLException if a database access error occurs; this2396* method is called on a closed result set2397* or the result set concurrency is {@code CONCUR_READ_ONLY}2398* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2399* this method2400* @since 1.22401*/2402void moveToInsertRow() throws SQLException;24032404/**2405* Moves the cursor to the remembered cursor position, usually the2406* current row. This method has no effect if the cursor is not on2407* the insert row.2408*2409* @throws SQLException if a database access error occurs; this2410* method is called on a closed result set2411* or the result set concurrency is {@code CONCUR_READ_ONLY}2412* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2413* this method2414* @since 1.22415*/2416void moveToCurrentRow() throws SQLException;24172418/**2419* Retrieves the {@code Statement} object that produced this2420* {@code ResultSet} object.2421* If the result set was generated some other way, such as by a2422* {@code DatabaseMetaData} method, this method may return2423* {@code null}.2424*2425* @return the {@code Statement} object that produced2426* this {@code ResultSet} object or {@code null}2427* if the result set was produced some other way2428* @throws SQLException if a database access error occurs2429* or this method is called on a closed result set2430* @since 1.22431*/2432Statement getStatement() throws SQLException;24332434/**2435* Retrieves the value of the designated column in the current row2436* of this {@code ResultSet} object as an {@code Object}2437* in the Java programming language.2438* If the value is an SQL {@code NULL},2439* the driver returns a Java {@code null}.2440* This method uses the given {@code Map} object2441* for the custom mapping of the2442* SQL structured or distinct type that is being retrieved.2443*2444* @param columnIndex the first column is 1, the second is 2, ...2445* @param map a {@code java.util.Map} object that contains the mapping2446* from SQL type names to classes in the Java programming language2447* @return an {@code Object} in the Java programming language2448* representing the SQL value2449* @throws SQLException if the columnIndex is not valid;2450* if a database access error occurs2451* or this method is called on a closed result set2452* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2453* this method2454* @since 1.22455*/2456Object getObject(int columnIndex, java.util.Map<String,Class<?>> map)2457throws SQLException;24582459/**2460* Retrieves the value of the designated column in the current row2461* of this {@code ResultSet} object as a {@code Ref} object2462* in the Java programming language.2463*2464* @param columnIndex the first column is 1, the second is 2, ...2465* @return a {@code Ref} object representing an SQL {@code REF}2466* value2467* @throws SQLException if the columnIndex is not valid;2468* if a database access error occurs2469* or this method is called on a closed result set2470* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2471* this method2472* @since 1.22473*/2474Ref getRef(int columnIndex) throws SQLException;24752476/**2477* Retrieves the value of the designated column in the current row2478* of this {@code ResultSet} object as a {@code Blob} object2479* in the Java programming language.2480*2481* @param columnIndex the first column is 1, the second is 2, ...2482* @return a {@code Blob} object representing the SQL2483* {@code BLOB} value in the specified column2484* @throws SQLException if the columnIndex is not valid;2485* if a database access error occurs2486* or this method is called on a closed result set2487* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2488* this method2489* @since 1.22490*/2491Blob getBlob(int columnIndex) throws SQLException;24922493/**2494* Retrieves the value of the designated column in the current row2495* of this {@code ResultSet} object as a {@code Clob} object2496* in the Java programming language.2497*2498* @param columnIndex the first column is 1, the second is 2, ...2499* @return a {@code Clob} object representing the SQL2500* {@code CLOB} value in the specified column2501* @throws SQLException if the columnIndex is not valid;2502* if a database access error occurs2503* or this method is called on a closed result set2504* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2505* this method2506* @since 1.22507*/2508Clob getClob(int columnIndex) throws SQLException;25092510/**2511* Retrieves the value of the designated column in the current row2512* of this {@code ResultSet} object as an {@code Array} object2513* in the Java programming language.2514*2515* @param columnIndex the first column is 1, the second is 2, ...2516* @return an {@code Array} object representing the SQL2517* {@code ARRAY} value in the specified column2518* @throws SQLException if the columnIndex is not valid;2519* if a database access error occurs2520* or this method is called on a closed result set2521* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2522* this method2523* @since 1.22524*/2525Array getArray(int columnIndex) throws SQLException;25262527/**2528* Retrieves the value of the designated column in the current row2529* of this {@code ResultSet} object as an {@code Object}2530* in the Java programming language.2531* If the value is an SQL {@code NULL},2532* the driver returns a Java {@code null}.2533* This method uses the specified {@code Map} object for2534* custom mapping if appropriate.2535*2536* @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 column2537* @param map a {@code java.util.Map} object that contains the mapping2538* from SQL type names to classes in the Java programming language2539* @return an {@code Object} representing the SQL value in the2540* specified column2541* @throws SQLException if the columnLabel is not valid;2542* if a database access error occurs2543* or this method is called on a closed result set2544* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2545* this method2546* @since 1.22547*/2548Object getObject(String columnLabel, java.util.Map<String,Class<?>> map)2549throws SQLException;25502551/**2552* Retrieves the value of the designated column in the current row2553* of this {@code ResultSet} object as a {@code Ref} object2554* in the Java programming language.2555*2556* @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 column2557* @return a {@code Ref} object representing the SQL {@code REF}2558* value in the specified column2559* @throws SQLException if the columnLabel is not valid;2560* if a database access error occurs2561* or this method is called on a closed result set2562* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2563* this method2564* @since 1.22565*/2566Ref getRef(String columnLabel) throws SQLException;25672568/**2569* Retrieves the value of the designated column in the current row2570* of this {@code ResultSet} object as a {@code Blob} object2571* in the Java programming language.2572*2573* @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 column2574* @return a {@code Blob} object representing the SQL {@code BLOB}2575* value in the specified column2576* @throws SQLException if the columnLabel is not valid;2577* if a database access error occurs2578* or this method is called on a closed result set2579* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2580* this method2581* @since 1.22582*/2583Blob getBlob(String columnLabel) throws SQLException;25842585/**2586* Retrieves the value of the designated column in the current row2587* of this {@code ResultSet} object as a {@code Clob} object2588* in the Java programming language.2589*2590* @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 column2591* @return a {@code Clob} object representing the SQL {@code CLOB}2592* value in the specified column2593* @throws SQLException if the columnLabel is not valid;2594* if a database access error occurs2595* or this method is called on a closed result set2596* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2597* this method2598* @since 1.22599*/2600Clob getClob(String columnLabel) throws SQLException;26012602/**2603* Retrieves the value of the designated column in the current row2604* of this {@code ResultSet} object as an {@code Array} object2605* in the Java programming language.2606*2607* @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 column2608* @return an {@code Array} object representing the SQL {@code ARRAY} value in2609* the specified column2610* @throws SQLException if the columnLabel is not valid;2611* if a database access error occurs2612* or this method is called on a closed result set2613* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2614* this method2615* @since 1.22616*/2617Array getArray(String columnLabel) throws SQLException;26182619/**2620* Retrieves the value of the designated column in the current row2621* of this {@code ResultSet} object as a {@code java.sql.Date} object2622* in the Java programming language.2623* This method uses the given calendar to construct an appropriate millisecond2624* value for the date if the underlying database does not store2625* timezone information.2626*2627* @param columnIndex the first column is 1, the second is 2, ...2628* @param cal the {@code java.util.Calendar} object2629* to use in constructing the date2630* @return the column value as a {@code java.sql.Date} object;2631* if the value is SQL {@code NULL},2632* the value returned is {@code null} in the Java programming language2633* @throws SQLException if the columnIndex is not valid;2634* if a database access error occurs2635* or this method is called on a closed result set2636* @since 1.22637*/2638java.sql.Date getDate(int columnIndex, Calendar cal) throws SQLException;26392640/**2641* Retrieves the value of the designated column in the current row2642* of this {@code ResultSet} object as a {@code java.sql.Date} object2643* in the Java programming language.2644* This method uses the given calendar to construct an appropriate millisecond2645* value for the date if the underlying database does not store2646* timezone information.2647*2648* @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 column2649* @param cal the {@code java.util.Calendar} object2650* to use in constructing the date2651* @return the column value as a {@code java.sql.Date} object;2652* if the value is SQL {@code NULL},2653* the value returned is {@code null} in the Java programming language2654* @throws SQLException if the columnLabel is not valid;2655* if a database access error occurs2656* or this method is called on a closed result set2657* @since 1.22658*/2659java.sql.Date getDate(String columnLabel, Calendar cal) throws SQLException;26602661/**2662* Retrieves the value of the designated column in the current row2663* of this {@code ResultSet} object as a {@code java.sql.Time} object2664* in the Java programming language.2665* This method uses the given calendar to construct an appropriate millisecond2666* value for the time if the underlying database does not store2667* timezone information.2668*2669* @param columnIndex the first column is 1, the second is 2, ...2670* @param cal the {@code java.util.Calendar} object2671* to use in constructing the time2672* @return the column value as a {@code java.sql.Time} object;2673* if the value is SQL {@code NULL},2674* the value returned is {@code null} in the Java programming language2675* @throws SQLException if the columnIndex is not valid;2676* if a database access error occurs2677* or this method is called on a closed result set2678* @since 1.22679*/2680java.sql.Time getTime(int columnIndex, Calendar cal) throws SQLException;26812682/**2683* Retrieves the value of the designated column in the current row2684* of this {@code ResultSet} object as a {@code java.sql.Time} object2685* in the Java programming language.2686* This method uses the given calendar to construct an appropriate millisecond2687* value for the time if the underlying database does not store2688* timezone information.2689*2690* @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 column2691* @param cal the {@code java.util.Calendar} object2692* to use in constructing the time2693* @return the column value as a {@code java.sql.Time} object;2694* if the value is SQL {@code NULL},2695* the value returned is {@code null} in the Java programming language2696* @throws SQLException if the columnLabel is not valid;2697* if a database access error occurs2698* or this method is called on a closed result set2699* @since 1.22700*/2701java.sql.Time getTime(String columnLabel, Calendar cal) throws SQLException;27022703/**2704* Retrieves the value of the designated column in the current row2705* of this {@code ResultSet} object as a {@code java.sql.Timestamp} object2706* in the Java programming language.2707* This method uses the given calendar to construct an appropriate millisecond2708* value for the timestamp if the underlying database does not store2709* timezone information.2710*2711* @param columnIndex the first column is 1, the second is 2, ...2712* @param cal the {@code java.util.Calendar} object2713* to use in constructing the timestamp2714* @return the column value as a {@code java.sql.Timestamp} object;2715* if the value is SQL {@code NULL},2716* the value returned is {@code null} in the Java programming language2717* @throws SQLException if the columnIndex is not valid;2718* if a database access error occurs2719* or this method is called on a closed result set2720* @since 1.22721*/2722java.sql.Timestamp getTimestamp(int columnIndex, Calendar cal)2723throws SQLException;27242725/**2726* Retrieves the value of the designated column in the current row2727* of this {@code ResultSet} object as a {@code java.sql.Timestamp} object2728* in the Java programming language.2729* This method uses the given calendar to construct an appropriate millisecond2730* value for the timestamp if the underlying database does not store2731* timezone information.2732*2733* @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 column2734* @param cal the {@code java.util.Calendar} object2735* to use in constructing the date2736* @return the column value as a {@code java.sql.Timestamp} object;2737* if the value is SQL {@code NULL},2738* the value returned is {@code null} in the Java programming language2739* @throws SQLException if the columnLabel is not valid or2740* if a database access error occurs2741* or this method is called on a closed result set2742* @since 1.22743*/2744java.sql.Timestamp getTimestamp(String columnLabel, Calendar cal)2745throws SQLException;27462747//-------------------------- JDBC 3.0 ----------------------------------------27482749/**2750* The constant indicating that open {@code ResultSet} objects with this2751* holdability will remain open when the current transaction is committed.2752*2753* @since 1.42754*/2755int HOLD_CURSORS_OVER_COMMIT = 1;27562757/**2758* The constant indicating that open {@code ResultSet} objects with this2759* holdability will be closed when the current transaction is committed.2760*2761* @since 1.42762*/2763int CLOSE_CURSORS_AT_COMMIT = 2;27642765/**2766* Retrieves the value of the designated column in the current row2767* of this {@code ResultSet} object as a {@code java.net.URL}2768* object in the Java programming language.2769*2770* @param columnIndex the index of the column 1 is the first, 2 is the second,...2771* @return the column value as a {@code java.net.URL} object;2772* if the value is SQL {@code NULL},2773* the value returned is {@code null} in the Java programming language2774* @throws SQLException if the columnIndex is not valid;2775* if a database access error occurs; this method2776* is called on a closed result set or if a URL is malformed2777* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2778* this method2779* @since 1.42780*/2781java.net.URL getURL(int columnIndex) throws SQLException;27822783/**2784* Retrieves the value of the designated column in the current row2785* of this {@code ResultSet} object as a {@code java.net.URL}2786* object in the Java programming language.2787*2788* @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 column2789* @return the column value as a {@code java.net.URL} object;2790* if the value is SQL {@code NULL},2791* the value returned is {@code null} in the Java programming language2792* @throws SQLException if the columnLabel is not valid;2793* if a database access error occurs; this method2794* is called on a closed result set or if a URL is malformed2795* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2796* this method2797* @since 1.42798*/2799java.net.URL getURL(String columnLabel) throws SQLException;28002801/**2802* Updates the designated column with a {@code java.sql.Ref} value.2803* The updater methods are used to update column values in the2804* current row or the insert row. The updater methods do not2805* update the underlying database; instead the {@code updateRow} or2806* {@code insertRow} methods are called to update the database.2807*2808* @param columnIndex the first column is 1, the second is 2, ...2809* @param x the new column value2810* @throws SQLException if the columnIndex is not valid;2811* if a database access error occurs;2812* the result set concurrency is {@code CONCUR_READ_ONLY}2813* or this method is called on a closed result set2814* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2815* this method2816* @since 1.42817*/2818void updateRef(int columnIndex, java.sql.Ref x) throws SQLException;28192820/**2821* Updates the designated column with a {@code java.sql.Ref} value.2822* The updater methods are used to update column values in the2823* current row or the insert row. The updater methods do not2824* update the underlying database; instead the {@code updateRow} or2825* {@code insertRow} methods are called to update the database.2826*2827* @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 column2828* @param x the new column value2829* @throws SQLException if the columnLabel is not valid;2830* if a database access error occurs;2831* the result set concurrency is {@code CONCUR_READ_ONLY}2832* or this method is called on a closed result set2833* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2834* this method2835* @since 1.42836*/2837void updateRef(String columnLabel, java.sql.Ref x) throws SQLException;28382839/**2840* Updates the designated column with a {@code java.sql.Blob} value.2841* The updater methods are used to update column values in the2842* current row or the insert row. The updater methods do not2843* update the underlying database; instead the {@code updateRow} or2844* {@code insertRow} methods are called to update the database.2845*2846* @param columnIndex the first column is 1, the second is 2, ...2847* @param x the new column value2848* @throws SQLException if the columnIndex is not valid;2849* if a database access error occurs;2850* the result set concurrency is {@code CONCUR_READ_ONLY}2851* or this method is called on a closed result set2852* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2853* this method2854* @since 1.42855*/2856void updateBlob(int columnIndex, java.sql.Blob x) throws SQLException;28572858/**2859* Updates the designated column with a {@code java.sql.Blob} value.2860* The updater methods are used to update column values in the2861* current row or the insert row. The updater methods do not2862* update the underlying database; instead the {@code updateRow} or2863* {@code insertRow} methods are called to update the database.2864*2865* @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 column2866* @param x the new column value2867* @throws SQLException if the columnLabel is not valid;2868* if a database access error occurs;2869* the result set concurrency is {@code CONCUR_READ_ONLY}2870* or this method is called on a closed result set2871* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2872* this method2873* @since 1.42874*/2875void updateBlob(String columnLabel, java.sql.Blob x) throws SQLException;28762877/**2878* Updates the designated column with a {@code java.sql.Clob} value.2879* The updater methods are used to update column values in the2880* current row or the insert row. The updater methods do not2881* update the underlying database; instead the {@code updateRow} or2882* {@code insertRow} methods are called to update the database.2883*2884* @param columnIndex the first column is 1, the second is 2, ...2885* @param x the new column value2886* @throws SQLException if the columnIndex is not valid;2887* if a database access error occurs;2888* the result set concurrency is {@code CONCUR_READ_ONLY}2889* or this method is called on a closed result set2890* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2891* this method2892* @since 1.42893*/2894void updateClob(int columnIndex, java.sql.Clob x) throws SQLException;28952896/**2897* Updates the designated column with a {@code java.sql.Clob} value.2898* The updater methods are used to update column values in the2899* current row or the insert row. The updater methods do not2900* update the underlying database; instead the {@code updateRow} or2901* {@code insertRow} methods are called to update the database.2902*2903* @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 column2904* @param x the new column value2905* @throws SQLException if the columnLabel is not valid;2906* if a database access error occurs;2907* the result set concurrency is {@code CONCUR_READ_ONLY}2908* or this method is called on a closed result set2909* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2910* this method2911* @since 1.42912*/2913void updateClob(String columnLabel, java.sql.Clob x) throws SQLException;29142915/**2916* Updates the designated column with a {@code java.sql.Array} value.2917* The updater methods are used to update column values in the2918* current row or the insert row. The updater methods do not2919* update the underlying database; instead the {@code updateRow} or2920* {@code insertRow} methods are called to update the database.2921*2922* @param columnIndex the first column is 1, the second is 2, ...2923* @param x the new column value2924* @throws SQLException if the columnIndex is not valid;2925* if a database access error occurs;2926* the result set concurrency is {@code CONCUR_READ_ONLY}2927* or this method is called on a closed result set2928* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2929* this method2930* @since 1.42931*/2932void updateArray(int columnIndex, java.sql.Array x) throws SQLException;29332934/**2935* Updates the designated column with a {@code java.sql.Array} value.2936* The updater methods are used to update column values in the2937* current row or the insert row. The updater methods do not2938* update the underlying database; instead the {@code updateRow} or2939* {@code insertRow} methods are called to update the database.2940*2941* @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 column2942* @param x the new column value2943* @throws SQLException if the columnLabel is not valid;2944* if a database access error occurs;2945* the result set concurrency is {@code CONCUR_READ_ONLY}2946* or this method is called on a closed result set2947* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2948* this method2949* @since 1.42950*/2951void updateArray(String columnLabel, java.sql.Array x) throws SQLException;29522953//------------------------- JDBC 4.0 -----------------------------------29542955/**2956* Retrieves the value of the designated column in the current row of this2957* {@code ResultSet} object as a {@code java.sql.RowId} object in the Java2958* programming language.2959*2960* @param columnIndex the first column is 1, the second 2, ...2961* @return the column value; if the value is a SQL {@code NULL} the2962* value returned is {@code null}2963* @throws SQLException if the columnIndex is not valid;2964* if a database access error occurs2965* or this method is called on a closed result set2966* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2967* this method2968* @since 1.62969*/2970RowId getRowId(int columnIndex) throws SQLException;29712972/**2973* Retrieves the value of the designated column in the current row of this2974* {@code ResultSet} object as a {@code java.sql.RowId} object in the Java2975* programming language.2976*2977* @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 column2978* @return the column value ; if the value is a SQL {@code NULL} the2979* value returned is {@code null}2980* @throws SQLException if the columnLabel is not valid;2981* if a database access error occurs2982* or this method is called on a closed result set2983* @throws SQLFeatureNotSupportedException if the JDBC driver does not support2984* this method2985* @since 1.62986*/2987RowId getRowId(String columnLabel) throws SQLException;29882989/**2990* Updates the designated column with a {@code RowId} value. The updater2991* methods are used to update column values in the current row or the insert2992* row. The updater methods do not update the underlying database; instead2993* the {@code updateRow} or {@code insertRow} methods are called2994* to update the database.2995*2996* @param columnIndex the first column is 1, the second 2, ...2997* @param x the column value2998* @throws SQLException if the columnIndex is not valid;2999* if a database access error occurs;3000* the result set concurrency is {@code CONCUR_READ_ONLY}3001* or this method is called on a closed result set3002* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3003* this method3004* @since 1.63005*/3006void updateRowId(int columnIndex, RowId x) throws SQLException;30073008/**3009* Updates the designated column with a {@code RowId} value. The updater3010* methods are used to update column values in the current row or the insert3011* row. The updater methods do not update the underlying database; instead3012* the {@code updateRow} or {@code insertRow} methods are called3013* to update the database.3014*3015* @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 column3016* @param x the column value3017* @throws SQLException if the columnLabel is not valid;3018* if a database access error occurs;3019* the result set concurrency is {@code CONCUR_READ_ONLY}3020* or this method is called on a closed result set3021* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3022* this method3023* @since 1.63024*/3025void updateRowId(String columnLabel, RowId x) throws SQLException;30263027/**3028* Retrieves the holdability of this {@code ResultSet} object3029* @return either {@code ResultSet.HOLD_CURSORS_OVER_COMMIT} or {@code ResultSet.CLOSE_CURSORS_AT_COMMIT}3030* @throws SQLException if a database access error occurs3031* or this method is called on a closed result set3032* @since 1.63033*/3034int getHoldability() throws SQLException;30353036/**3037* Retrieves whether this {@code ResultSet} object has been closed. A {@code ResultSet} is closed if the3038* method close has been called on it, or if it is automatically closed.3039*3040* @return true if this {@code ResultSet} object is closed; false if it is still open3041* @throws SQLException if a database access error occurs3042* @since 1.63043*/3044boolean isClosed() throws SQLException;30453046/**3047* Updates the designated column with a {@code String} value.3048* It is intended for use when updating {@code NCHAR},{@code NVARCHAR}3049* and {@code LONGNVARCHAR} columns.3050* The updater methods are used to update column values in the3051* current row or the insert row. The updater methods do not3052* update the underlying database; instead the {@code updateRow} or3053* {@code insertRow} methods are called to update the database.3054*3055* @param columnIndex the first column is 1, the second 2, ...3056* @param nString the value for the column to be updated3057* @throws SQLException if the columnIndex is not valid;3058* if the driver does not support national3059* character sets; if the driver can detect that a data conversion3060* error could occur; this method is called on a closed result set;3061* the result set concurrency is {@code CONCUR_READ_ONLY}3062* or if a database access error occurs3063* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3064* this method3065* @since 1.63066*/3067void updateNString(int columnIndex, String nString) throws SQLException;30683069/**3070* Updates the designated column with a {@code String} value.3071* It is intended for use when updating {@code NCHAR},{@code NVARCHAR}3072* and {@code LONGNVARCHAR} columns.3073* The updater methods are used to update column values in the3074* current row or the insert row. The updater methods do not3075* update the underlying database; instead the {@code updateRow} or3076* {@code insertRow} methods are called to update the database.3077*3078* @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 column3079* @param nString the value for the column to be updated3080* @throws SQLException if the columnLabel is not valid;3081* if the driver does not support national3082* character sets; if the driver can detect that a data conversion3083* error could occur; this method is called on a closed result set;3084* the result set concurrency is {@code CONCUR_READ_ONLY}3085* or if a database access error occurs3086* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3087* this method3088* @since 1.63089*/3090void updateNString(String columnLabel, String nString) throws SQLException;30913092/**3093* Updates the designated column with a {@code java.sql.NClob} value.3094* The updater methods are used to update column values in the3095* current row or the insert row. The updater methods do not3096* update the underlying database; instead the {@code updateRow} or3097* {@code insertRow} methods are called to update the database.3098*3099* @param columnIndex the first column is 1, the second 2, ...3100* @param nClob the value for the column to be updated3101* @throws SQLException if the columnIndex is not valid;3102* if the driver does not support national3103* character sets; if the driver can detect that a data conversion3104* error could occur; this method is called on a closed result set;3105* if a database access error occurs or3106* the result set concurrency is {@code CONCUR_READ_ONLY}3107* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3108* this method3109* @since 1.63110*/3111void updateNClob(int columnIndex, NClob nClob) throws SQLException;31123113/**3114* Updates the designated column with a {@code java.sql.NClob} value.3115* The updater methods are used to update column values in the3116* current row or the insert row. The updater methods do not3117* update the underlying database; instead the {@code updateRow} or3118* {@code insertRow} methods are called to update the database.3119*3120* @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 column3121* @param nClob the value for the column to be updated3122* @throws SQLException if the columnLabel is not valid;3123* if the driver does not support national3124* character sets; if the driver can detect that a data conversion3125* error could occur; this method is called on a closed result set;3126* if a database access error occurs or3127* the result set concurrency is {@code CONCUR_READ_ONLY}3128* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3129* this method3130* @since 1.63131*/3132void updateNClob(String columnLabel, NClob nClob) throws SQLException;31333134/**3135* Retrieves the value of the designated column in the current row3136* of this {@code ResultSet} object as a {@code NClob} object3137* in the Java programming language.3138*3139* @param columnIndex the first column is 1, the second is 2, ...3140* @return a {@code NClob} object representing the SQL3141* {@code NCLOB} value in the specified column3142* @throws SQLException if the columnIndex is not valid;3143* if the driver does not support national3144* character sets; if the driver can detect that a data conversion3145* error could occur; this method is called on a closed result set3146* or if a database access error occurs3147* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3148* this method3149* @since 1.63150*/3151NClob getNClob(int columnIndex) throws SQLException;31523153/**3154* Retrieves the value of the designated column in the current row3155* of this {@code ResultSet} object as a {@code NClob} object3156* in the Java programming language.3157*3158* @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 column3159* @return a {@code NClob} object representing the SQL {@code NCLOB}3160* value in the specified column3161* @throws SQLException if the columnLabel is not valid;3162* if the driver does not support national3163* character sets; if the driver can detect that a data conversion3164* error could occur; this method is called on a closed result set3165* or if a database access error occurs3166* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3167* this method3168* @since 1.63169*/3170NClob getNClob(String columnLabel) throws SQLException;31713172/**3173* Retrieves the value of the designated column in the current row of3174* this {@code ResultSet} as a3175* {@code java.sql.SQLXML} object in the Java programming language.3176* @param columnIndex the first column is 1, the second is 2, ...3177* @return a {@code SQLXML} object that maps an {@code SQL XML} value3178* @throws SQLException if the columnIndex is not valid;3179* if a database access error occurs3180* or this method is called on a closed result set3181* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3182* this method3183* @since 1.63184*/3185SQLXML getSQLXML(int columnIndex) throws SQLException;31863187/**3188* Retrieves the value of the designated column in the current row of3189* this {@code ResultSet} as a3190* {@code java.sql.SQLXML} object in the Java programming language.3191* @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 column3192* @return a {@code SQLXML} object that maps an {@code SQL XML} value3193* @throws SQLException if the columnLabel is not valid;3194* if a database access error occurs3195* or this method is called on a closed result set3196* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3197* this method3198* @since 1.63199*/3200SQLXML getSQLXML(String columnLabel) throws SQLException;3201/**3202* Updates the designated column with a {@code java.sql.SQLXML} value.3203* The updater3204* methods are used to update column values in the current row or the insert3205* row. The updater methods do not update the underlying database; instead3206* the {@code updateRow} or {@code insertRow} methods are called3207* to update the database.3208*3209* @param columnIndex the first column is 1, the second 2, ...3210* @param xmlObject the value for the column to be updated3211* @throws SQLException if the columnIndex is not valid;3212* if a database access error occurs; this method3213* is called on a closed result set;3214* the {@code java.xml.transform.Result},3215* {@code Writer} or {@code OutputStream} has not been closed3216* for the {@code SQLXML} object;3217* if there is an error processing the XML value or3218* the result set concurrency is {@code CONCUR_READ_ONLY}. The {@code getCause} method3219* of the exception may provide a more detailed exception, for example, if the3220* stream does not contain valid XML.3221* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3222* this method3223* @since 1.63224*/3225void updateSQLXML(int columnIndex, SQLXML xmlObject) throws SQLException;3226/**3227* Updates the designated column with a {@code java.sql.SQLXML} value.3228* The updater3229* methods are used to update column values in the current row or the insert3230* row. The updater methods do not update the underlying database; instead3231* the {@code updateRow} or {@code insertRow} methods are called3232* to update the database.3233*3234* @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 column3235* @param xmlObject the column value3236* @throws SQLException if the columnLabel is not valid;3237* if a database access error occurs; this method3238* is called on a closed result set;3239* the {@code java.xml.transform.Result},3240* {@code Writer} or {@code OutputStream} has not been closed3241* for the {@code SQLXML} object;3242* if there is an error processing the XML value or3243* the result set concurrency is {@code CONCUR_READ_ONLY}. The {@code getCause} method3244* of the exception may provide a more detailed exception, for example, if the3245* stream does not contain valid XML.3246* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3247* this method3248* @since 1.63249*/3250void updateSQLXML(String columnLabel, SQLXML xmlObject) throws SQLException;32513252/**3253* Retrieves the value of the designated column in the current row3254* of this {@code ResultSet} object as3255* a {@code String} in the Java programming language.3256* It is intended for use when3257* accessing {@code NCHAR},{@code NVARCHAR}3258* and {@code LONGNVARCHAR} columns.3259*3260* @param columnIndex the first column is 1, the second is 2, ...3261* @return the column value; if the value is SQL {@code NULL}, the3262* value returned is {@code null}3263* @throws SQLException if the columnIndex is not valid;3264* if a database access error occurs3265* or this method is called on a closed result set3266* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3267* this method3268* @since 1.63269*/3270String getNString(int columnIndex) throws SQLException;327132723273/**3274* Retrieves the value of the designated column in the current row3275* of this {@code ResultSet} object as3276* a {@code String} in the Java programming language.3277* It is intended for use when3278* accessing {@code NCHAR},{@code NVARCHAR}3279* and {@code LONGNVARCHAR} columns.3280*3281* @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 column3282* @return the column value; if the value is SQL {@code NULL}, the3283* value returned is {@code null}3284* @throws SQLException if the columnLabel is not valid;3285* if a database access error occurs3286* or this method is called on a closed result set3287* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3288* this method3289* @since 1.63290*/3291String getNString(String columnLabel) throws SQLException;329232933294/**3295* Retrieves the value of the designated column in the current row3296* of this {@code ResultSet} object as a3297* {@code java.io.Reader} object.3298* It is intended for use when3299* accessing {@code NCHAR},{@code NVARCHAR}3300* and {@code LONGNVARCHAR} columns.3301*3302* @return a {@code java.io.Reader} object that contains the column3303* value; if the value is SQL {@code NULL}, the value returned is3304* {@code null} in the Java programming language.3305* @param columnIndex the first column is 1, the second is 2, ...3306* @throws SQLException if the columnIndex is not valid;3307* if a database access error occurs3308* or this method is called on a closed result set3309* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3310* this method3311* @since 1.63312*/3313java.io.Reader getNCharacterStream(int columnIndex) throws SQLException;33143315/**3316* Retrieves the value of the designated column in the current row3317* of this {@code ResultSet} object as a3318* {@code java.io.Reader} object.3319* It is intended for use when3320* accessing {@code NCHAR},{@code NVARCHAR}3321* and {@code LONGNVARCHAR} columns.3322*3323* @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 column3324* @return a {@code java.io.Reader} object that contains the column3325* value; if the value is SQL {@code NULL}, the value returned is3326* {@code null} in the Java programming language3327* @throws SQLException if the columnLabel is not valid;3328* if a database access error occurs3329* or this method is called on a closed result set3330* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3331* this method3332* @since 1.63333*/3334java.io.Reader getNCharacterStream(String columnLabel) throws SQLException;33353336/**3337* Updates the designated column with a character stream value, which will have3338* the specified number of bytes. The3339* driver does the necessary conversion from Java character format to3340* the national character set in the database.3341* It is intended for use when3342* updating {@code NCHAR},{@code NVARCHAR}3343* and {@code LONGNVARCHAR} columns.3344* <p>3345* The updater methods are used to update column values in the3346* current row or the insert row. The updater methods do not3347* update the underlying database; instead the {@code updateRow} or3348* {@code insertRow} methods are called to update the database.3349*3350* @param columnIndex the first column is 1, the second is 2, ...3351* @param x the new column value3352* @param length the length of the stream3353* @throws SQLException if the columnIndex is not valid;3354* if a database access error occurs;3355* the result set concurrency is {@code CONCUR_READ_ONLY} or this method is called on a closed result set3356* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3357* this method3358* @since 1.63359*/3360void updateNCharacterStream(int columnIndex,3361java.io.Reader x,3362long length) throws SQLException;33633364/**3365* Updates the designated column with a character stream value, which will have3366* the specified number of bytes. The3367* driver does the necessary conversion from Java character format to3368* the national character set in the database.3369* It is intended for use when3370* updating {@code NCHAR},{@code NVARCHAR}3371* and {@code LONGNVARCHAR} columns.3372* <p>3373* The updater methods are used to update column values in the3374* current row or the insert row. The updater methods do not3375* update the underlying database; instead the {@code updateRow} or3376* {@code insertRow} methods are called to update the database.3377*3378* @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 column3379* @param reader the {@code java.io.Reader} object containing3380* the new column value3381* @param length the length of the stream3382* @throws SQLException if the columnLabel is not valid;3383* if a database access error occurs;3384* the result set concurrency is {@code CONCUR_READ_ONLY} or this method is called on a closed result set3385* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3386* this method3387* @since 1.63388*/3389void updateNCharacterStream(String columnLabel,3390java.io.Reader reader,3391long length) throws SQLException;3392/**3393* Updates the designated column with an ascii stream value, which will have3394* the specified number of bytes.3395* <p>3396* The updater methods are used to update column values in the3397* current row or the insert row. The updater methods do not3398* update the underlying database; instead the {@code updateRow} or3399* {@code insertRow} methods are called to update the database.3400*3401* @param columnIndex the first column is 1, the second is 2, ...3402* @param x the new column value3403* @param length the length of the stream3404* @throws SQLException if the columnIndex is not valid;3405* if a database access error occurs;3406* the result set concurrency is {@code CONCUR_READ_ONLY}3407* or this method is called on a closed result set3408* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3409* this method3410* @since 1.63411*/3412void updateAsciiStream(int columnIndex,3413java.io.InputStream x,3414long length) throws SQLException;34153416/**3417* Updates the designated column with a binary stream value, which will have3418* the specified number of bytes.3419* <p>3420* The updater methods are used to update column values in the3421* current row or the insert row. The updater methods do not3422* update the underlying database; instead the {@code updateRow} or3423* {@code insertRow} methods are called to update the database.3424*3425* @param columnIndex the first column is 1, the second is 2, ...3426* @param x the new column value3427* @param length the length of the stream3428* @throws SQLException if the columnIndex is not valid;3429* if a database access error occurs;3430* the result set concurrency is {@code CONCUR_READ_ONLY}3431* or this method is called on a closed result set3432* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3433* this method3434* @since 1.63435*/3436void updateBinaryStream(int columnIndex,3437java.io.InputStream x,3438long length) throws SQLException;34393440/**3441* Updates the designated column with a character stream value, which will have3442* the specified number of bytes.3443* <p>3444* The updater methods are used to update column values in the3445* current row or the insert row. The updater methods do not3446* update the underlying database; instead the {@code updateRow} or3447* {@code insertRow} methods are called to update the database.3448*3449* @param columnIndex the first column is 1, the second is 2, ...3450* @param x the new column value3451* @param length the length of the stream3452* @throws SQLException if the columnIndex is not valid;3453* if a database access error occurs;3454* the result set concurrency is {@code CONCUR_READ_ONLY}3455* or this method is called on a closed result set3456* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3457* this method3458* @since 1.63459*/3460void updateCharacterStream(int columnIndex,3461java.io.Reader x,3462long length) throws SQLException;3463/**3464* Updates the designated column with an ascii stream value, which will have3465* the specified number of bytes.3466* <p>3467* The updater methods are used to update column values in the3468* current row or the insert row. The updater methods do not3469* update the underlying database; instead the {@code updateRow} or3470* {@code insertRow} methods are called to update the database.3471*3472* @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 column3473* @param x the new column value3474* @param length the length of the stream3475* @throws SQLException if the columnLabel is not valid;3476* if a database access error occurs;3477* the result set concurrency is {@code CONCUR_READ_ONLY}3478* or this method is called on a closed result set3479* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3480* this method3481* @since 1.63482*/3483void updateAsciiStream(String columnLabel,3484java.io.InputStream x,3485long length) throws SQLException;34863487/**3488* Updates the designated column with a binary stream value, which will have3489* the specified number of bytes.3490* <p>3491* The updater methods are used to update column values in the3492* current row or the insert row. The updater methods do not3493* update the underlying database; instead the {@code updateRow} or3494* {@code insertRow} methods are called to update the database.3495*3496* @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 column3497* @param x the new column value3498* @param length the length of the stream3499* @throws SQLException if the columnLabel is not valid;3500* if a database access error occurs;3501* the result set concurrency is {@code CONCUR_READ_ONLY}3502* or this method is called on a closed result set3503* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3504* this method3505* @since 1.63506*/3507void updateBinaryStream(String columnLabel,3508java.io.InputStream x,3509long length) throws SQLException;35103511/**3512* Updates the designated column with a character stream value, which will have3513* the specified number of bytes.3514* <p>3515* The updater methods are used to update column values in the3516* current row or the insert row. The updater methods do not3517* update the underlying database; instead the {@code updateRow} or3518* {@code insertRow} methods are called to update the database.3519*3520* @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 column3521* @param reader the {@code java.io.Reader} object containing3522* the new column value3523* @param length the length of the stream3524* @throws SQLException if the columnLabel is not valid;3525* if a database access error occurs;3526* the result set concurrency is {@code CONCUR_READ_ONLY}3527* or this method is called on a closed result set3528* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3529* this method3530* @since 1.63531*/3532void updateCharacterStream(String columnLabel,3533java.io.Reader reader,3534long length) throws SQLException;3535/**3536* Updates the designated column using the given input stream, which3537* will have the specified number of bytes.3538*3539* <p>3540* The updater methods are used to update column values in the3541* current row or the insert row. The updater methods do not3542* update the underlying database; instead the {@code updateRow} or3543* {@code insertRow} methods are called to update the database.3544*3545* @param columnIndex the first column is 1, the second is 2, ...3546* @param inputStream An object that contains the data to set the parameter3547* value to.3548* @param length the number of bytes in the parameter data.3549* @throws SQLException if the columnIndex is not valid;3550* if a database access error occurs;3551* the result set concurrency is {@code CONCUR_READ_ONLY}3552* or this method is called on a closed result set3553* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3554* this method3555* @since 1.63556*/3557void updateBlob(int columnIndex, InputStream inputStream, long length) throws SQLException;35583559/**3560* Updates the designated column using the given input stream, which3561* will have the specified number of bytes.3562*3563* <p>3564* The updater methods are used to update column values in the3565* current row or the insert row. The updater methods do not3566* update the underlying database; instead the {@code updateRow} or3567* {@code insertRow} methods are called to update the database.3568*3569* @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 column3570* @param inputStream An object that contains the data to set the parameter3571* value to.3572* @param length the number of bytes in the parameter data.3573* @throws SQLException if the columnLabel is not valid;3574* if a database access error occurs;3575* the result set concurrency is {@code CONCUR_READ_ONLY}3576* or this method is called on a closed result set3577* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3578* this method3579* @since 1.63580*/3581void updateBlob(String columnLabel, InputStream inputStream, long length) throws SQLException;35823583/**3584* Updates the designated column using the given {@code Reader}3585* object, which is the given number of characters long.3586* When a very large UNICODE value is input to a {@code LONGVARCHAR}3587* parameter, it may be more practical to send it via a3588* {@code java.io.Reader} object. The JDBC driver will3589* do any necessary conversion from UNICODE to the database char format.3590*3591* <p>3592* The updater methods are used to update column values in the3593* current row or the insert row. The updater methods do not3594* update the underlying database; instead the {@code updateRow} or3595* {@code insertRow} methods are called to update the database.3596*3597* @param columnIndex the first column is 1, the second is 2, ...3598* @param reader An object that contains the data to set the parameter value to.3599* @param length the number of characters in the parameter data.3600* @throws SQLException if the columnIndex is not valid;3601* if a database access error occurs;3602* the result set concurrency is {@code CONCUR_READ_ONLY}3603* or this method is called on a closed result set3604* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3605* this method3606* @since 1.63607*/3608void updateClob(int columnIndex, Reader reader, long length) throws SQLException;36093610/**3611* Updates the designated column using the given {@code Reader}3612* object, which is the given number of characters long.3613* When a very large UNICODE value is input to a {@code LONGVARCHAR}3614* parameter, it may be more practical to send it via a3615* {@code java.io.Reader} object. The JDBC driver will3616* do any necessary conversion from UNICODE to the database char format.3617*3618* <p>3619* The updater methods are used to update column values in the3620* current row or the insert row. The updater methods do not3621* update the underlying database; instead the {@code updateRow} or3622* {@code insertRow} methods are called to update the database.3623*3624* @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 column3625* @param reader An object that contains the data to set the parameter value to.3626* @param length the number of characters in the parameter data.3627* @throws SQLException if the columnLabel is not valid;3628* if a database access error occurs;3629* the result set concurrency is {@code CONCUR_READ_ONLY}3630* or this method is called on a closed result set3631* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3632* this method3633* @since 1.63634*/3635void updateClob(String columnLabel, Reader reader, long length) throws SQLException;3636/**3637* Updates the designated column using the given {@code Reader}3638* object, which is the given number of characters long.3639* When a very large UNICODE value is input to a {@code LONGVARCHAR}3640* parameter, it may be more practical to send it via a3641* {@code java.io.Reader} object. The JDBC driver will3642* do any necessary conversion from UNICODE to the database char format.3643*3644* <p>3645* The updater methods are used to update column values in the3646* current row or the insert row. The updater methods do not3647* update the underlying database; instead the {@code updateRow} or3648* {@code insertRow} methods are called to update the database.3649*3650* @param columnIndex the first column is 1, the second 2, ...3651* @param reader An object that contains the data to set the parameter value to.3652* @param length the number of characters in the parameter data.3653* @throws SQLException if the columnIndex is not valid;3654* if the driver does not support national3655* character sets; if the driver can detect that a data conversion3656* error could occur; this method is called on a closed result set,3657* if a database access error occurs or3658* the result set concurrency is {@code CONCUR_READ_ONLY}3659* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3660* this method3661* @since 1.63662*/3663void updateNClob(int columnIndex, Reader reader, long length) throws SQLException;36643665/**3666* Updates the designated column using the given {@code Reader}3667* object, which is the given number of characters long.3668* When a very large UNICODE value is input to a {@code LONGVARCHAR}3669* parameter, it may be more practical to send it via a3670* {@code java.io.Reader} object. The JDBC driver will3671* do any necessary conversion from UNICODE to the database char format.3672*3673* <p>3674* The updater methods are used to update column values in the3675* current row or the insert row. The updater methods do not3676* update the underlying database; instead the {@code updateRow} or3677* {@code insertRow} methods are called to update the database.3678*3679* @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 column3680* @param reader An object that contains the data to set the parameter value to.3681* @param length the number of characters in the parameter data.3682* @throws SQLException if the columnLabel is not valid;3683* if the driver does not support national3684* character sets; if the driver can detect that a data conversion3685* error could occur; this method is called on a closed result set;3686* if a database access error occurs or3687* the result set concurrency is {@code CONCUR_READ_ONLY}3688* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3689* this method3690* @since 1.63691*/3692void updateNClob(String columnLabel, Reader reader, long length) throws SQLException;36933694//---36953696/**3697* Updates the designated column with a character stream value.3698* The data will be read from the stream3699* as needed until end-of-stream is reached. The3700* driver does the necessary conversion from Java character format to3701* the national character set in the database.3702* It is intended for use when3703* updating {@code NCHAR},{@code NVARCHAR}3704* and {@code LONGNVARCHAR} columns.3705* <p>3706* The updater methods are used to update column values in the3707* current row or the insert row. The updater methods do not3708* update the underlying database; instead the {@code updateRow} or3709* {@code insertRow} methods are called to update the database.3710*3711* <P><B>Note:</B> Consult your JDBC driver documentation to determine if3712* it might be more efficient to use a version of3713* {@code updateNCharacterStream} which takes a length parameter.3714*3715* @param columnIndex the first column is 1, the second is 2, ...3716* @param x the new column value3717* @throws SQLException if the columnIndex is not valid;3718* if a database access error occurs;3719* the result set concurrency is {@code CONCUR_READ_ONLY} or this method is called on a closed result set3720* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3721* this method3722* @since 1.63723*/3724void updateNCharacterStream(int columnIndex,3725java.io.Reader x) throws SQLException;37263727/**3728* Updates the designated column with a character stream value.3729* The data will be read from the stream3730* as needed until end-of-stream is reached. The3731* driver does the necessary conversion from Java character format to3732* the national character set in the database.3733* It is intended for use when3734* updating {@code NCHAR},{@code NVARCHAR}3735* and {@code LONGNVARCHAR} columns.3736* <p>3737* The updater methods are used to update column values in the3738* current row or the insert row. The updater methods do not3739* update the underlying database; instead the {@code updateRow} or3740* {@code insertRow} methods are called to update the database.3741*3742* <P><B>Note:</B> Consult your JDBC driver documentation to determine if3743* it might be more efficient to use a version of3744* {@code updateNCharacterStream} which takes a length parameter.3745*3746* @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 column3747* @param reader the {@code java.io.Reader} object containing3748* the new column value3749* @throws SQLException if the columnLabel is not valid;3750* if a database access error occurs;3751* the result set concurrency is {@code CONCUR_READ_ONLY} or this method is called on a closed result set3752* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3753* this method3754* @since 1.63755*/3756void updateNCharacterStream(String columnLabel,3757java.io.Reader reader) throws SQLException;3758/**3759* Updates the designated column with an ascii stream value.3760* The data will be read from the stream3761* as needed until end-of-stream is reached.3762* <p>3763* The updater methods are used to update column values in the3764* current row or the insert row. The updater methods do not3765* update the underlying database; instead the {@code updateRow} or3766* {@code insertRow} methods are called to update the database.3767*3768* <P><B>Note:</B> Consult your JDBC driver documentation to determine if3769* it might be more efficient to use a version of3770* {@code updateAsciiStream} which takes a length parameter.3771*3772* @param columnIndex the first column is 1, the second is 2, ...3773* @param x the new column value3774* @throws SQLException if the columnIndex is not valid;3775* if a database access error occurs;3776* the result set concurrency is {@code CONCUR_READ_ONLY}3777* or this method is called on a closed result set3778* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3779* this method3780* @since 1.63781*/3782void updateAsciiStream(int columnIndex,3783java.io.InputStream x) throws SQLException;37843785/**3786* Updates the designated column with a binary stream value.3787* The data will be read from the stream3788* as needed until end-of-stream is reached.3789* <p>3790* The updater methods are used to update column values in the3791* current row or the insert row. The updater methods do not3792* update the underlying database; instead the {@code updateRow} or3793* {@code insertRow} methods are called to update the database.3794*3795* <P><B>Note:</B> Consult your JDBC driver documentation to determine if3796* it might be more efficient to use a version of3797* {@code updateBinaryStream} which takes a length parameter.3798*3799* @param columnIndex the first column is 1, the second is 2, ...3800* @param x the new column value3801* @throws SQLException if the columnIndex is not valid;3802* if a database access error occurs;3803* the result set concurrency is {@code CONCUR_READ_ONLY}3804* or this method is called on a closed result set3805* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3806* this method3807* @since 1.63808*/3809void updateBinaryStream(int columnIndex,3810java.io.InputStream x) throws SQLException;38113812/**3813* Updates the designated column with a character stream value.3814* The data will be read from the stream3815* as needed until end-of-stream is reached.3816* <p>3817* The updater methods are used to update column values in the3818* current row or the insert row. The updater methods do not3819* update the underlying database; instead the {@code updateRow} or3820* {@code insertRow} methods are called to update the database.3821*3822* <P><B>Note:</B> Consult your JDBC driver documentation to determine if3823* it might be more efficient to use a version of3824* {@code updateCharacterStream} which takes a length parameter.3825*3826* @param columnIndex the first column is 1, the second is 2, ...3827* @param x the new column value3828* @throws SQLException if the columnIndex is not valid;3829* if a database access error occurs;3830* the result set concurrency is {@code CONCUR_READ_ONLY}3831* or this method is called on a closed result set3832* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3833* this method3834* @since 1.63835*/3836void updateCharacterStream(int columnIndex,3837java.io.Reader x) throws SQLException;3838/**3839* Updates the designated column with an ascii stream value.3840* The data will be read from the stream3841* as needed until end-of-stream is reached.3842* <p>3843* The updater methods are used to update column values in the3844* current row or the insert row. The updater methods do not3845* update the underlying database; instead the {@code updateRow} or3846* {@code insertRow} methods are called to update the database.3847*3848* <P><B>Note:</B> Consult your JDBC driver documentation to determine if3849* it might be more efficient to use a version of3850* {@code updateAsciiStream} which takes a length parameter.3851*3852* @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 column3853* @param x the new column value3854* @throws SQLException if the columnLabel is not valid;3855* if a database access error occurs;3856* the result set concurrency is {@code CONCUR_READ_ONLY}3857* or this method is called on a closed result set3858* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3859* this method3860* @since 1.63861*/3862void updateAsciiStream(String columnLabel,3863java.io.InputStream x) throws SQLException;38643865/**3866* Updates the designated column with a binary stream value.3867* The data will be read from the stream3868* as needed until end-of-stream is reached.3869* <p>3870* The updater methods are used to update column values in the3871* current row or the insert row. The updater methods do not3872* update the underlying database; instead the {@code updateRow} or3873* {@code insertRow} methods are called to update the database.3874*3875* <P><B>Note:</B> Consult your JDBC driver documentation to determine if3876* it might be more efficient to use a version of3877* {@code updateBinaryStream} which takes a length parameter.3878*3879* @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 column3880* @param x the new column value3881* @throws SQLException if the columnLabel is not valid;3882* if a database access error occurs;3883* the result set concurrency is {@code CONCUR_READ_ONLY}3884* or this method is called on a closed result set3885* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3886* this method3887* @since 1.63888*/3889void updateBinaryStream(String columnLabel,3890java.io.InputStream x) throws SQLException;38913892/**3893* Updates the designated column with a character stream value.3894* The data will be read from the stream3895* as needed until end-of-stream is reached.3896* <p>3897* The updater methods are used to update column values in the3898* current row or the insert row. The updater methods do not3899* update the underlying database; instead the {@code updateRow} or3900* {@code insertRow} methods are called to update the database.3901*3902* <P><B>Note:</B> Consult your JDBC driver documentation to determine if3903* it might be more efficient to use a version of3904* {@code updateCharacterStream} which takes a length parameter.3905*3906* @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 column3907* @param reader the {@code java.io.Reader} object containing3908* the new column value3909* @throws SQLException if the columnLabel is not valid; if a database access error occurs;3910* the result set concurrency is {@code CONCUR_READ_ONLY}3911* or this method is called on a closed result set3912* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3913* this method3914* @since 1.63915*/3916void updateCharacterStream(String columnLabel,3917java.io.Reader reader) throws SQLException;3918/**3919* Updates the designated column using the given input stream. The data will be read from the stream3920* as needed until end-of-stream is reached.3921* <p>3922* The updater methods are used to update column values in the3923* current row or the insert row. The updater methods do not3924* update the underlying database; instead the {@code updateRow} or3925* {@code insertRow} methods are called to update the database.3926*3927* <P><B>Note:</B> Consult your JDBC driver documentation to determine if3928* it might be more efficient to use a version of3929* {@code updateBlob} which takes a length parameter.3930*3931* @param columnIndex the first column is 1, the second is 2, ...3932* @param inputStream An object that contains the data to set the parameter3933* value to.3934* @throws SQLException if the columnIndex is not valid; if a database access error occurs;3935* the result set concurrency is {@code CONCUR_READ_ONLY}3936* or this method is called on a closed result set3937* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3938* this method3939* @since 1.63940*/3941void updateBlob(int columnIndex, InputStream inputStream) throws SQLException;39423943/**3944* Updates the designated column using the given input stream. The data will be read from the stream3945* as needed until end-of-stream is reached.3946* <p>3947* The updater methods are used to update column values in the3948* current row or the insert row. The updater methods do not3949* update the underlying database; instead the {@code updateRow} or3950* {@code insertRow} methods are called to update the database.3951*3952* <P><B>Note:</B> Consult your JDBC driver documentation to determine if3953* it might be more efficient to use a version of3954* {@code updateBlob} which takes a length parameter.3955*3956* @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 column3957* @param inputStream An object that contains the data to set the parameter3958* value to.3959* @throws SQLException if the columnLabel is not valid; if a database access error occurs;3960* the result set concurrency is {@code CONCUR_READ_ONLY}3961* or this method is called on a closed result set3962* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3963* this method3964* @since 1.63965*/3966void updateBlob(String columnLabel, InputStream inputStream) throws SQLException;39673968/**3969* Updates the designated column using the given {@code Reader}3970* object.3971* The data will be read from the stream3972* as needed until end-of-stream is reached. The JDBC driver will3973* do any necessary conversion from UNICODE to the database char format.3974*3975* <p>3976* The updater methods are used to update column values in the3977* current row or the insert row. The updater methods do not3978* update the underlying database; instead the {@code updateRow} or3979* {@code insertRow} methods are called to update the database.3980*3981* <P><B>Note:</B> Consult your JDBC driver documentation to determine if3982* it might be more efficient to use a version of3983* {@code updateClob} which takes a length parameter.3984*3985* @param columnIndex the first column is 1, the second is 2, ...3986* @param reader An object that contains the data to set the parameter value to.3987* @throws SQLException if the columnIndex is not valid;3988* if a database access error occurs;3989* the result set concurrency is {@code CONCUR_READ_ONLY}3990* or this method is called on a closed result set3991* @throws SQLFeatureNotSupportedException if the JDBC driver does not support3992* this method3993* @since 1.63994*/3995void updateClob(int columnIndex, Reader reader) throws SQLException;39963997/**3998* Updates the designated column using the given {@code Reader}3999* object.4000* The data will be read from the stream4001* as needed until end-of-stream is reached. The JDBC driver will4002* do any necessary conversion from UNICODE to the database char format.4003*4004* <p>4005* The updater methods are used to update column values in the4006* current row or the insert row. The updater methods do not4007* update the underlying database; instead the {@code updateRow} or4008* {@code insertRow} methods are called to update the database.4009*4010* <P><B>Note:</B> Consult your JDBC driver documentation to determine if4011* it might be more efficient to use a version of4012* {@code updateClob} which takes a length parameter.4013*4014* @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 column4015* @param reader An object that contains the data to set the parameter value to.4016* @throws SQLException if the columnLabel is not valid; if a database access error occurs;4017* the result set concurrency is {@code CONCUR_READ_ONLY}4018* or this method is called on a closed result set4019* @throws SQLFeatureNotSupportedException if the JDBC driver does not support4020* this method4021* @since 1.64022*/4023void updateClob(String columnLabel, Reader reader) throws SQLException;4024/**4025* Updates the designated column using the given {@code Reader}4026*4027* The data will be read from the stream4028* as needed until end-of-stream is reached. The JDBC driver will4029* do any necessary conversion from UNICODE to the database char format.4030*4031* <p>4032* The updater methods are used to update column values in the4033* current row or the insert row. The updater methods do not4034* update the underlying database; instead the {@code updateRow} or4035* {@code insertRow} methods are called to update the database.4036*4037* <P><B>Note:</B> Consult your JDBC driver documentation to determine if4038* it might be more efficient to use a version of4039* {@code updateNClob} which takes a length parameter.4040*4041* @param columnIndex the first column is 1, the second 2, ...4042* @param reader An object that contains the data to set the parameter value to.4043* @throws SQLException if the columnIndex is not valid;4044* if the driver does not support national4045* character sets; if the driver can detect that a data conversion4046* error could occur; this method is called on a closed result set,4047* if a database access error occurs or4048* the result set concurrency is {@code CONCUR_READ_ONLY}4049* @throws SQLFeatureNotSupportedException if the JDBC driver does not support4050* this method4051* @since 1.64052*/4053void updateNClob(int columnIndex, Reader reader) throws SQLException;40544055/**4056* Updates the designated column using the given {@code Reader}4057* object.4058* The data will be read from the stream4059* as needed until end-of-stream is reached. The JDBC driver will4060* do any necessary conversion from UNICODE to the database char format.4061*4062* <p>4063* The updater methods are used to update column values in the4064* current row or the insert row. The updater methods do not4065* update the underlying database; instead the {@code updateRow} or4066* {@code insertRow} methods are called to update the database.4067*4068* <P><B>Note:</B> Consult your JDBC driver documentation to determine if4069* it might be more efficient to use a version of4070* {@code updateNClob} which takes a length parameter.4071*4072* @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 column4073* @param reader An object that contains the data to set the parameter value to.4074* @throws SQLException if the columnLabel is not valid; if the driver does not support national4075* character sets; if the driver can detect that a data conversion4076* error could occur; this method is called on a closed result set;4077* if a database access error occurs or4078* the result set concurrency is {@code CONCUR_READ_ONLY}4079* @throws SQLFeatureNotSupportedException if the JDBC driver does not support4080* this method4081* @since 1.64082*/4083void updateNClob(String columnLabel, Reader reader) throws SQLException;40844085//------------------------- JDBC 4.1 -----------------------------------408640874088/**4089*<p>Retrieves the value of the designated column in the current row4090* of this {@code ResultSet} object and will convert from the4091* SQL type of the column to the requested Java data type, if the4092* conversion is supported. If the conversion is not4093* supported or null is specified for the type, a4094* {@code SQLException} is thrown.4095*<p>4096* At a minimum, an implementation must support the conversions defined in4097* Appendix B, Table B-3 and conversion of appropriate user defined SQL4098* types to a Java type which implements {@code SQLData}, or {@code Struct}.4099* Additional conversions may be supported and are vendor defined.4100* @param <T> the type of the class modeled by this Class object4101* @param columnIndex the first column is 1, the second is 2, ...4102* @param type Class representing the Java data type to convert the designated4103* column to.4104* @return an instance of {@code type} holding the column value4105* @throws SQLException if conversion is not supported, type is null or4106* another error occurs. The getCause() method of the4107* exception may provide a more detailed exception, for example, if4108* a conversion error occurs4109* @throws SQLFeatureNotSupportedException if the JDBC driver does not support4110* this method4111* @since 1.74112*/4113public <T> T getObject(int columnIndex, Class<T> type) throws SQLException;411441154116/**4117*<p>Retrieves the value of the designated column in the current row4118* of this {@code ResultSet} object and will convert from the4119* SQL type of the column to the requested Java data type, if the4120* conversion is supported. If the conversion is not4121* supported or null is specified for the type, a4122* {@code SQLException} is thrown.4123*<p>4124* At a minimum, an implementation must support the conversions defined in4125* Appendix B, Table B-3 and conversion of appropriate user defined SQL4126* types to a Java type which implements {@code SQLData}, or {@code Struct}.4127* Additional conversions may be supported and are vendor defined.4128*4129* @param columnLabel the label for the column specified with the SQL AS clause.4130* If the SQL AS clause was not specified, then the label is the name4131* of the column4132* @param type Class representing the Java data type to convert the designated4133* column to.4134* @param <T> the type of the class modeled by this Class object4135* @return an instance of {@code type} holding the column value4136* @throws SQLException if conversion is not supported, type is null or4137* another error occurs. The getCause() method of the4138* exception may provide a more detailed exception, for example, if4139* a conversion error occurs4140* @throws SQLFeatureNotSupportedException if the JDBC driver does not support4141* this method4142* @since 1.74143*/4144public <T> T getObject(String columnLabel, Class<T> type) throws SQLException;41454146//------------------------- JDBC 4.2 -----------------------------------41474148/**4149* Updates the designated column with an {@code Object} value.4150*4151* The updater methods are used to update column values in the4152* current row or the insert row. The updater methods do not4153* update the underlying database; instead the {@code updateRow} or4154* {@code insertRow} methods are called to update the database.4155*<p>4156* If the second argument is an {@code InputStream} then the stream must contain4157* the number of bytes specified by scaleOrLength. If the second argument is a4158* {@code Reader} then the reader must contain the number of characters specified4159* by scaleOrLength. If these conditions are not true the driver will generate a4160* {@code SQLException} when the statement is executed.4161*<p>4162* The default implementation will throw {@code SQLFeatureNotSupportedException}4163*4164* @param columnIndex the first column is 1, the second is 2, ...4165* @param x the new column value4166* @param targetSqlType the SQL type to be sent to the database4167* @param scaleOrLength for an object of {@code java.math.BigDecimal} ,4168* this is the number of digits after the decimal point. For4169* Java Object types {@code InputStream} and {@code Reader},4170* this is the length4171* of the data in the stream or reader. For all other types,4172* this value will be ignored.4173* @throws SQLException if the columnIndex is not valid;4174* if a database access error occurs;4175* the result set concurrency is {@code CONCUR_READ_ONLY}4176* or this method is called on a closed result set4177* @throws SQLFeatureNotSupportedException if the JDBC driver does not4178* support this method; if the JDBC driver does not support the specified targetSqlType4179* @see JDBCType4180* @see SQLType4181* @since 1.84182*/4183default void updateObject(int columnIndex, Object x,4184SQLType targetSqlType, int scaleOrLength) throws SQLException {4185throw new SQLFeatureNotSupportedException("updateObject not implemented");4186}41874188/**4189* Updates the designated column with an {@code Object} value.4190*4191* The updater methods are used to update column values in the4192* current row or the insert row. The updater methods do not4193* update the underlying database; instead the {@code updateRow} or4194* {@code insertRow} methods are called to update the database.4195*<p>4196* If the second argument is an {@code InputStream} then the stream must4197* contain number of bytes specified by scaleOrLength. If the second4198* argument is a {@code Reader} then the reader must contain the number4199* of characters specified by scaleOrLength. If these conditions are not4200* true the driver will generate a4201* {@code SQLException} when the statement is executed.4202*<p>4203* The default implementation will throw {@code SQLFeatureNotSupportedException}4204*4205* @param columnLabel the label for the column specified with the SQL AS4206* clause. If the SQL AS clause was not specified, then the label is4207* the name of the column4208* @param x the new column value4209* @param targetSqlType the SQL type to be sent to the database4210* @param scaleOrLength for an object of {@code java.math.BigDecimal} ,4211* this is the number of digits after the decimal point. For4212* Java Object types {@code InputStream} and {@code Reader},4213* this is the length4214* of the data in the stream or reader. For all other types,4215* this value will be ignored.4216* @throws SQLException if the columnLabel is not valid;4217* if a database access error occurs;4218* the result set concurrency is {@code CONCUR_READ_ONLY}4219* or this method is called on a closed result set4220* @throws SQLFeatureNotSupportedException if the JDBC driver does not4221* support this method; if the JDBC driver does not support the specified targetSqlType4222* @see JDBCType4223* @see SQLType4224* @since 1.84225*/4226default void updateObject(String columnLabel, Object x,4227SQLType targetSqlType, int scaleOrLength) throws SQLException {4228throw new SQLFeatureNotSupportedException("updateObject not implemented");4229}42304231/**4232* Updates the designated column with an {@code Object} value.4233*4234* The updater methods are used to update column values in the4235* current row or the insert row. The updater methods do not4236* update the underlying database; instead the {@code updateRow} or4237* {@code insertRow} methods are called to update the database.4238*<p>4239* The default implementation will throw {@code SQLFeatureNotSupportedException}4240*4241* @param columnIndex the first column is 1, the second is 2, ...4242* @param x the new column value4243* @param targetSqlType the SQL type to be sent to the database4244* @throws SQLException if the columnIndex is not valid;4245* if a database access error occurs;4246* the result set concurrency is {@code CONCUR_READ_ONLY}4247* or this method is called on a closed result set4248* @throws SQLFeatureNotSupportedException if the JDBC driver does not4249* support this method; if the JDBC driver does not support the specified targetSqlType4250* @see JDBCType4251* @see SQLType4252* @since 1.84253*/4254default void updateObject(int columnIndex, Object x, SQLType targetSqlType)4255throws SQLException {4256throw new SQLFeatureNotSupportedException("updateObject not implemented");4257}42584259/**4260* Updates the designated column with an {@code Object} value.4261*4262* The updater methods are used to update column values in the4263* current row or the insert row. The updater methods do not4264* update the underlying database; instead the {@code updateRow} or4265* {@code insertRow} methods are called to update the database.4266*<p>4267* The default implementation will throw {@code SQLFeatureNotSupportedException}4268*4269* @param columnLabel the label for the column specified with the SQL AS4270* clause. If the SQL AS clause was not specified, then the label is4271* the name of the column4272* @param x the new column value4273* @param targetSqlType the SQL type to be sent to the database4274* @throws SQLException if the columnLabel is not valid;4275* if a database access error occurs;4276* the result set concurrency is {@code CONCUR_READ_ONLY}4277* or this method is called on a closed result set4278* @throws SQLFeatureNotSupportedException if the JDBC driver does not4279* support this method; if the JDBC driver does not support the specified targetSqlType4280* @see JDBCType4281* @see SQLType4282* @since 1.84283*/4284default void updateObject(String columnLabel, Object x,4285SQLType targetSqlType) throws SQLException {4286throw new SQLFeatureNotSupportedException("updateObject not implemented");4287}4288}428942904291