Class JdbcResultSet
- All Implemented Interfaces:
AutoCloseable
,ResultSet
,Wrapper
Column labels are case-insensitive, quotes are not supported. The first column has the column index 1.
Thread safety: the result set is not thread-safe and must not be used by multiple threads concurrently.
Updatable result sets: Result sets are updatable when the result only contains columns from one table, and if it contains all columns of a unique index (primary key or other) of this table. Key columns may not contain NULL (because multiple rows with NULL could exist). In updatable result sets, own changes are visible, but not own inserts and deletes.
-
Field Summary
Fields inherited from class org.h2.message.TraceObject
ARRAY, BLOB, CALLABLE_STATEMENT, CLOB, CONNECTION, DATA_SOURCE, DATABASE_META_DATA, PARAMETER_META_DATA, PREPARED_STATEMENT, RESULT_SET, RESULT_SET_META_DATA, SAVEPOINT, SQLXML, STATEMENT, trace, XA_DATA_SOURCE, XID
Fields inherited from interface java.sql.ResultSet
CLOSE_CURSORS_AT_COMMIT, CONCUR_READ_ONLY, CONCUR_UPDATABLE, FETCH_FORWARD, FETCH_REVERSE, FETCH_UNKNOWN, HOLD_CURSORS_OVER_COMMIT, TYPE_FORWARD_ONLY, TYPE_SCROLL_INSENSITIVE, TYPE_SCROLL_SENSITIVE
-
Constructor Summary
ConstructorDescriptionJdbcResultSet
(JdbcConnection conn, JdbcStatement stat, org.h2.command.CommandInterface command, org.h2.result.ResultInterface result, int id, boolean scrollable, boolean updatable, boolean triggerUpdatable) -
Method Summary
Modifier and TypeMethodDescriptionboolean
absolute
(int rowNumber) Moves the current position to a specific row.void
Moves the current position to after the last row, that means after the end.void
Moves the current position to before the first row, that means resets the result set.void
Cancels updating a row.void
Clears all warnings.void
close()
Closes the result set.void
Deletes the current row.int
findColumn
(String columnLabel) Searches for a specific column in the result set.boolean
first()
Moves the current position to the first row.getArray
(int columnIndex) Returns the value of the specified column as an Array.Returns the value of the specified column as an Array.getAsciiStream
(int columnIndex) Returns the value of the specified column as an input stream.getAsciiStream
(String columnLabel) Returns the value of the specified column as an input stream.getBigDecimal
(int columnIndex) Returns the value of the specified column as a BigDecimal.getBigDecimal
(int columnIndex, int scale) Deprecated.getBigDecimal
(String columnLabel) Returns the value of the specified column as a BigDecimal.getBigDecimal
(String columnLabel, int scale) Deprecated.getBinaryStream
(int columnIndex) Returns the value of the specified column as an input stream.getBinaryStream
(String columnLabel) Returns the value of the specified column as an input stream.getBlob
(int columnIndex) Returns the value of the specified column as a Blob.Returns the value of the specified column as a Blob.boolean
getBoolean
(int columnIndex) Returns the value of the specified column as a boolean.boolean
getBoolean
(String columnLabel) Returns the value of the specified column as a boolean.byte
getByte
(int columnIndex) Returns the value of the specified column as a byte.byte
Returns the value of the specified column as a byte.byte[]
getBytes
(int columnIndex) Returns the value of the specified column as a byte array.byte[]
Returns the value of the specified column as a byte array.getCharacterStream
(int columnIndex) Returns the value of the specified column as a reader.getCharacterStream
(String columnLabel) Returns the value of the specified column as a reader.getClob
(int columnIndex) Returns the value of the specified column as a Clob.Returns the value of the specified column as a Clob.int
Gets the result set concurrency.[Not supported] Gets the cursor name if it was defined.getDate
(int columnIndex) Returns the value of the specified column as a java.sql.Date.Returns the value of the specified column as a java.sql.Date using a specified time zone.Returns the value of the specified column as a java.sql.Date.Returns the value of the specified column as a java.sql.Date using a specified time zone.double
getDouble
(int columnIndex) Returns the value of the specified column as a double.double
Returns the value of the specified column as a double.int
Gets the fetch direction.int
Gets the number of rows suggested to read in one step.float
getFloat
(int columnIndex) Returns the value of the specified column as a float.float
Returns the value of the specified column as a float.int
Returns the current result set holdability.int
getInt
(int columnIndex) Returns the value of the specified column as an int.int
Returns the value of the specified column as an int.org.h2.value.Value
getInternal
(int columnIndex) INTERNALlong
getLong
(int columnIndex) Returns the value of the specified column as a long.long
Returns the value of the specified column as a long.Gets the meta data of this result set.getNCharacterStream
(int columnIndex) Returns the value of the specified column as a reader.getNCharacterStream
(String columnLabel) Returns the value of the specified column as a reader.getNClob
(int columnIndex) Returns the value of the specified column as a Clob.Returns the value of the specified column as a Clob.getNString
(int columnIndex) Returns the value of the specified column as a String.getNString
(String columnLabel) Returns the value of the specified column as a String.getObject
(int columnIndex) Returns a column value as a Java object.<T> T
Returns a column value as a Java object of the specified type.[Not supported] Gets a column as a object using the specified type mapping.Returns a column value as a Java object.<T> T
Returns a column value as a Java object of the specified type.[Not supported] Gets a column as a object using the specified type mapping.getRef
(int columnIndex) [Not supported] Gets a column as a reference.[Not supported] Gets a column as a reference.org.h2.result.ResultInterface
INTERNALint
getRow()
Gets the current row number.getRowId
(int columnIndex) [Not supported] Returns the value of the specified column as a row id.[Not supported] Returns the value of the specified column as a row id.short
getShort
(int columnIndex) Returns the value of the specified column as a short.short
Returns the value of the specified column as a short.getSQLXML
(int columnIndex) Returns the value of the specified column as a SQLXML.Returns the value of the specified column as a SQLXML.Returns the statement that created this object.getString
(int columnIndex) Returns the value of the specified column as a String.Returns the value of the specified column as a String.getTime
(int columnIndex) Returns the value of the specified column as a java.sql.Time.Returns the value of the specified column as a java.sql.Time using a specified time zone.Returns the value of the specified column as a java.sql.Time.Returns the value of the specified column as a java.sql.Time using a specified time zone.getTimestamp
(int columnIndex) Returns the value of the specified column as a java.sql.Timestamp.getTimestamp
(int columnIndex, Calendar calendar) Returns the value of the specified column as a java.sql.Timestamp using a specified time zone.getTimestamp
(String columnLabel) Returns the value of the specified column as a java.sql.Timestamp.getTimestamp
(String columnLabel, Calendar calendar) Returns the value of the specified column as a java.sql.Timestamp.int
getType()
Get the result set type.getUnicodeStream
(int columnIndex) Deprecated.since JDBC 2.0, use getCharacterStreamgetUnicodeStream
(String columnLabel) Deprecated.since JDBC 2.0, use setCharacterStreamorg.h2.value.Value[]
INTERNALgetURL
(int columnIndex) [Not supported][Not supported]Gets the first warning reported by calls on this object.void
Inserts the current row.boolean
Checks if the current position is after the last row, that means next() was called and returned false, and there was at least one row.boolean
Checks if the current position is before the first row, that means next() was not called yet, and there is at least one row.boolean
isClosed()
Returns whether this result set is closed.boolean
isFirst()
Checks if the current position is row 1, that means next() was called once and returned true.boolean
isLast()
Checks if the current position is the last row, that means next() was called and did not yet returned false, but will in the next call.boolean
isWrapperFor
(Class<?> iface) Checks if unwrap can return an object of this class.boolean
last()
Moves the current position to the last row.void
Moves the current position to the current row.void
Moves the current position to the insert row.boolean
next()
Moves the cursor to the next row of the result set.boolean
previous()
Moves the cursor to the last row, or row before first row if the current position is the first row.void
Re-reads the current row from the database.boolean
relative
(int rowCount) Moves the current position to a specific row relative to the current row.boolean
Detects if the row was deleted (by somebody else or the caller).boolean
Detects if the row was inserted.boolean
Detects if the row was updated (by somebody else or the caller).void
setFetchDirection
(int direction) [Not supported] Sets (changes) the fetch direction for this result set.void
setFetchSize
(int rows) Sets the number of rows suggested to read in one step.toString()
INTERNAL<T> T
Return an object of this class if possible.void
updateArray
(int columnIndex, Array x) Updates a column in the current or insert row.void
updateArray
(String columnLabel, Array x) Updates a column in the current or insert row.void
updateAsciiStream
(int columnIndex, InputStream x) Updates a column in the current or insert row.void
updateAsciiStream
(int columnIndex, InputStream x, int length) Updates a column in the current or insert row.void
updateAsciiStream
(int columnIndex, InputStream x, long length) Updates a column in the current or insert row.void
updateAsciiStream
(String columnLabel, InputStream x) Updates a column in the current or insert row.void
updateAsciiStream
(String columnLabel, InputStream x, int length) Updates a column in the current or insert row.void
updateAsciiStream
(String columnLabel, InputStream x, long length) Updates a column in the current or insert row.void
updateBigDecimal
(int columnIndex, BigDecimal x) Updates a column in the current or insert row.void
updateBigDecimal
(String columnLabel, BigDecimal x) Updates a column in the current or insert row.void
updateBinaryStream
(int columnIndex, InputStream x) Updates a column in the current or insert row.void
updateBinaryStream
(int columnIndex, InputStream x, int length) Updates a column in the current or insert row.void
updateBinaryStream
(int columnIndex, InputStream x, long length) Updates a column in the current or insert row.void
updateBinaryStream
(String columnLabel, InputStream x) Updates a column in the current or insert row.void
updateBinaryStream
(String columnLabel, InputStream x, int length) Updates a column in the current or insert row.void
updateBinaryStream
(String columnLabel, InputStream x, long length) Updates a column in the current or insert row.void
updateBlob
(int columnIndex, InputStream x) Updates a column in the current or insert row.void
updateBlob
(int columnIndex, InputStream x, long length) Updates a column in the current or insert row.void
updateBlob
(int columnIndex, Blob x) Updates a column in the current or insert row.void
updateBlob
(String columnLabel, InputStream x) Updates a column in the current or insert row.void
updateBlob
(String columnLabel, InputStream x, long length) Updates a column in the current or insert row.void
updateBlob
(String columnLabel, Blob x) Updates a column in the current or insert row.void
updateBoolean
(int columnIndex, boolean x) Updates a column in the current or insert row.void
updateBoolean
(String columnLabel, boolean x) Updates a column in the current or insert row.void
updateByte
(int columnIndex, byte x) Updates a column in the current or insert row.void
updateByte
(String columnLabel, byte x) Updates a column in the current or insert row.void
updateBytes
(int columnIndex, byte[] x) Updates a column in the current or insert row.void
updateBytes
(String columnLabel, byte[] x) Updates a column in the current or insert row.void
updateCharacterStream
(int columnIndex, Reader x) Updates a column in the current or insert row.void
updateCharacterStream
(int columnIndex, Reader x, int length) Updates a column in the current or insert row.void
updateCharacterStream
(int columnIndex, Reader x, long length) Updates a column in the current or insert row.void
updateCharacterStream
(String columnLabel, Reader x) Updates a column in the current or insert row.void
updateCharacterStream
(String columnLabel, Reader x, int length) Updates a column in the current or insert row.void
updateCharacterStream
(String columnLabel, Reader x, long length) Updates a column in the current or insert row.void
updateClob
(int columnIndex, Reader x) Updates a column in the current or insert row.void
updateClob
(int columnIndex, Reader x, long length) Updates a column in the current or insert row.void
updateClob
(int columnIndex, Clob x) Updates a column in the current or insert row.void
updateClob
(String columnLabel, Reader x) Updates a column in the current or insert row.void
updateClob
(String columnLabel, Reader x, long length) Updates a column in the current or insert row.void
updateClob
(String columnLabel, Clob x) Updates a column in the current or insert row.void
updateDate
(int columnIndex, Date x) Updates a column in the current or insert row.void
updateDate
(String columnLabel, Date x) Updates a column in the current or insert row.void
updateDouble
(int columnIndex, double x) Updates a column in the current or insert row.void
updateDouble
(String columnLabel, double x) Updates a column in the current or insert row.void
updateFloat
(int columnIndex, float x) Updates a column in the current or insert row.void
updateFloat
(String columnLabel, float x) Updates a column in the current or insert row.void
updateInt
(int columnIndex, int x) Updates a column in the current or insert row.void
Updates a column in the current or insert row.void
updateLong
(int columnIndex, long x) Updates a column in the current or insert row.void
updateLong
(String columnLabel, long x) Updates a column in the current or insert row.void
updateNCharacterStream
(int columnIndex, Reader x) Updates a column in the current or insert row.void
updateNCharacterStream
(int columnIndex, Reader x, long length) Updates a column in the current or insert row.void
updateNCharacterStream
(String columnLabel, Reader x) Updates a column in the current or insert row.void
updateNCharacterStream
(String columnLabel, Reader x, long length) Updates a column in the current or insert row.void
updateNClob
(int columnIndex, Reader x) Updates a column in the current or insert row.void
updateNClob
(int columnIndex, Reader x, long length) Updates a column in the current or insert row.void
updateNClob
(int columnIndex, NClob x) Updates a column in the current or insert row.void
updateNClob
(String columnLabel, Reader x) Updates a column in the current or insert row.void
updateNClob
(String columnLabel, Reader x, long length) Updates a column in the current or insert row.void
updateNClob
(String columnLabel, NClob x) Updates a column in the current or insert row.void
updateNString
(int columnIndex, String x) Updates a column in the current or insert row.void
updateNString
(String columnLabel, String x) Updates a column in the current or insert row.void
updateNull
(int columnIndex) Updates a column in the current or insert row.void
updateNull
(String columnLabel) Updates a column in the current or insert row.void
updateObject
(int columnIndex, Object x) Updates a column in the current or insert row.void
updateObject
(int columnIndex, Object x, int scale) Updates a column in the current or insert row.void
updateObject
(int columnIndex, Object x, SQLType targetSqlType) Updates a column in the current or insert row.void
updateObject
(int columnIndex, Object x, SQLType targetSqlType, int scaleOrLength) Updates a column in the current or insert row.void
updateObject
(String columnLabel, Object x) Updates a column in the current or insert row.void
updateObject
(String columnLabel, Object x, int scale) Updates a column in the current or insert row.void
updateObject
(String columnLabel, Object x, SQLType targetSqlType) Updates a column in the current or insert row.void
updateObject
(String columnLabel, Object x, SQLType targetSqlType, int scaleOrLength) Updates a column in the current or insert row.void
[Not supported]void
[Not supported]void
Updates the current row.void
updateRowId
(int columnIndex, RowId x) [Not supported] Updates a column in the current or insert row.void
updateRowId
(String columnLabel, RowId x) [Not supported] Updates a column in the current or insert row.void
updateShort
(int columnIndex, short x) Updates a column in the current or insert row.void
updateShort
(String columnLabel, short x) Updates a column in the current or insert row.void
updateSQLXML
(int columnIndex, SQLXML xmlObject) Updates a column in the current or insert row.void
updateSQLXML
(String columnLabel, SQLXML xmlObject) Updates a column in the current or insert row.void
updateString
(int columnIndex, String x) Updates a column in the current or insert row.void
updateString
(String columnLabel, String x) Updates a column in the current or insert row.void
updateTime
(int columnIndex, Time x) Updates a column in the current or insert row.void
updateTime
(String columnLabel, Time x) Updates a column in the current or insert row.void
updateTimestamp
(int columnIndex, Timestamp x) Updates a column in the current or insert row.void
updateTimestamp
(String columnLabel, Timestamp x) Updates a column in the current or insert row.boolean
wasNull()
Returns whether the last column accessed was null.Methods inherited from class org.h2.message.TraceObject
debugCode, debugCodeAssign, debugCodeCall, debugCodeCall, debugCodeCall, getNextId, getTraceId, getTraceObjectName, isDebugEnabled, isInfoEnabled, logAndConvert, quote, quoteArray, quoteBigDecimal, quoteBytes, quoteDate, quoteIntArray, quoteMap, quoteTime, quoteTimestamp, setTrace, unsupported
-
Constructor Details
-
JdbcResultSet
public JdbcResultSet(JdbcConnection conn, JdbcStatement stat, org.h2.command.CommandInterface command, org.h2.result.ResultInterface result, int id, boolean scrollable, boolean updatable, boolean triggerUpdatable)
-
-
Method Details
-
next
Moves the cursor to the next row of the result set.- Specified by:
next
in interfaceResultSet
- Returns:
- true if successful, false if there are no more rows
- Throws:
SQLException
-
getMetaData
Gets the meta data of this result set.- Specified by:
getMetaData
in interfaceResultSet
- Returns:
- the meta data
- Throws:
SQLException
-
wasNull
Returns whether the last column accessed was null.- Specified by:
wasNull
in interfaceResultSet
- Returns:
- true if the last column accessed was null
- Throws:
SQLException
-
findColumn
Searches for a specific column in the result set. A case-insensitive search is made.- Specified by:
findColumn
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the column index (1,2,...)
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
close
Closes the result set.- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceResultSet
- Throws:
SQLException
-
getStatement
Returns the statement that created this object.- Specified by:
getStatement
in interfaceResultSet
- Returns:
- the statement or prepared statement, or null if created by a DatabaseMetaData call.
- Throws:
SQLException
-
getWarnings
Gets the first warning reported by calls on this object.- Specified by:
getWarnings
in interfaceResultSet
- Returns:
- null
- Throws:
SQLException
-
clearWarnings
Clears all warnings.- Specified by:
clearWarnings
in interfaceResultSet
- Throws:
SQLException
-
getString
Returns the value of the specified column as a String.- Specified by:
getString
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getString
Returns the value of the specified column as a String.- Specified by:
getString
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getInt
Returns the value of the specified column as an int.- Specified by:
getInt
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getInt
Returns the value of the specified column as an int.- Specified by:
getInt
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getBigDecimal
Returns the value of the specified column as a BigDecimal.- Specified by:
getBigDecimal
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getDate
Returns the value of the specified column as a java.sql.Date.Usage of this method is discouraged. Use
getObject(columnIndex, LocalDate.class)
instead.- Specified by:
getDate
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed- See Also:
-
getTime
Returns the value of the specified column as a java.sql.Time.Usage of this method is discouraged. Use
getObject(columnIndex, LocalTime.class)
instead.- Specified by:
getTime
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed- See Also:
-
getTimestamp
Returns the value of the specified column as a java.sql.Timestamp.Usage of this method is discouraged. Use
getObject(columnIndex, LocalDateTime.class)
instead.- Specified by:
getTimestamp
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed- See Also:
-
getBigDecimal
Returns the value of the specified column as a BigDecimal.- Specified by:
getBigDecimal
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getDate
Returns the value of the specified column as a java.sql.Date.Usage of this method is discouraged. Use
getObject(columnLabel, LocalDate.class)
instead.- Specified by:
getDate
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed- See Also:
-
getTime
Returns the value of the specified column as a java.sql.Time.Usage of this method is discouraged. Use
getObject(columnLabel, LocalTime.class)
instead.- Specified by:
getTime
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed- See Also:
-
getTimestamp
Returns the value of the specified column as a java.sql.Timestamp.Usage of this method is discouraged. Use
getObject(columnLabel, LocalDateTime.class)
instead.- Specified by:
getTimestamp
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed- See Also:
-
getObject
Returns a column value as a Java object. The data is de-serialized into a Java object (on the client side).- Specified by:
getObject
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value or null
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getObject
Returns a column value as a Java object. The data is de-serialized into a Java object (on the client side).- Specified by:
getObject
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value or null
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getBoolean
Returns the value of the specified column as a boolean.- Specified by:
getBoolean
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getBoolean
Returns the value of the specified column as a boolean.- Specified by:
getBoolean
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getByte
Returns the value of the specified column as a byte.- Specified by:
getByte
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getByte
Returns the value of the specified column as a byte.- Specified by:
getByte
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getShort
Returns the value of the specified column as a short.- Specified by:
getShort
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getShort
Returns the value of the specified column as a short.- Specified by:
getShort
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getLong
Returns the value of the specified column as a long.- Specified by:
getLong
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getLong
Returns the value of the specified column as a long.- Specified by:
getLong
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getFloat
Returns the value of the specified column as a float.- Specified by:
getFloat
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getFloat
Returns the value of the specified column as a float.- Specified by:
getFloat
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getDouble
Returns the value of the specified column as a double.- Specified by:
getDouble
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getDouble
Returns the value of the specified column as a double.- Specified by:
getDouble
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getBigDecimal
Deprecated.Returns the value of the specified column as a BigDecimal.- Specified by:
getBigDecimal
in interfaceResultSet
- Parameters:
columnLabel
- the column labelscale
- the scale of the returned value- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getBigDecimal
Deprecated.Returns the value of the specified column as a BigDecimal.- Specified by:
getBigDecimal
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)scale
- the scale of the returned value- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getUnicodeStream
Deprecated.since JDBC 2.0, use getCharacterStream[Not supported]- Specified by:
getUnicodeStream
in interfaceResultSet
- Throws:
SQLException
-
getUnicodeStream
Deprecated.since JDBC 2.0, use setCharacterStream[Not supported]- Specified by:
getUnicodeStream
in interfaceResultSet
- Throws:
SQLException
-
getObject
[Not supported] Gets a column as a object using the specified type mapping.- Specified by:
getObject
in interfaceResultSet
- Throws:
SQLException
-
getObject
[Not supported] Gets a column as a object using the specified type mapping.- Specified by:
getObject
in interfaceResultSet
- Throws:
SQLException
-
getRef
[Not supported] Gets a column as a reference.- Specified by:
getRef
in interfaceResultSet
- Throws:
SQLException
-
getRef
[Not supported] Gets a column as a reference.- Specified by:
getRef
in interfaceResultSet
- Throws:
SQLException
-
getDate
Returns the value of the specified column as a java.sql.Date using a specified time zone.Usage of this method is discouraged. Use
getObject(columnIndex, LocalDate.class)
instead.- Specified by:
getDate
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)calendar
- the calendar- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed- See Also:
-
getDate
Returns the value of the specified column as a java.sql.Date using a specified time zone.Usage of this method is discouraged. Use
getObject(columnLabel, LocalDate.class)
instead.- Specified by:
getDate
in interfaceResultSet
- Parameters:
columnLabel
- the column labelcalendar
- the calendar- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed- See Also:
-
getTime
Returns the value of the specified column as a java.sql.Time using a specified time zone.Usage of this method is discouraged. Use
getObject(columnIndex, LocalTime.class)
instead.- Specified by:
getTime
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)calendar
- the calendar- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed- See Also:
-
getTime
Returns the value of the specified column as a java.sql.Time using a specified time zone.Usage of this method is discouraged. Use
getObject(columnLabel, LocalTime.class)
instead.- Specified by:
getTime
in interfaceResultSet
- Parameters:
columnLabel
- the column labelcalendar
- the calendar- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed- See Also:
-
getTimestamp
Returns the value of the specified column as a java.sql.Timestamp using a specified time zone.Usage of this method is discouraged. Use
getObject(columnIndex, LocalDateTime.class)
instead.- Specified by:
getTimestamp
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)calendar
- the calendar- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed- See Also:
-
getTimestamp
Returns the value of the specified column as a java.sql.Timestamp.Usage of this method is discouraged. Use
getObject(columnLabel, LocalDateTime.class)
instead.- Specified by:
getTimestamp
in interfaceResultSet
- Parameters:
columnLabel
- the column labelcalendar
- the calendar- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed- See Also:
-
getBlob
Returns the value of the specified column as a Blob.- Specified by:
getBlob
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getBlob
Returns the value of the specified column as a Blob.- Specified by:
getBlob
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getBytes
Returns the value of the specified column as a byte array.- Specified by:
getBytes
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getBytes
Returns the value of the specified column as a byte array.- Specified by:
getBytes
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getBinaryStream
Returns the value of the specified column as an input stream.- Specified by:
getBinaryStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getBinaryStream
Returns the value of the specified column as an input stream.- Specified by:
getBinaryStream
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getClob
Returns the value of the specified column as a Clob.- Specified by:
getClob
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getClob
Returns the value of the specified column as a Clob.- Specified by:
getClob
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getArray
Returns the value of the specified column as an Array.- Specified by:
getArray
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getArray
Returns the value of the specified column as an Array.- Specified by:
getArray
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getAsciiStream
Returns the value of the specified column as an input stream.- Specified by:
getAsciiStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getAsciiStream
Returns the value of the specified column as an input stream.- Specified by:
getAsciiStream
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getCharacterStream
Returns the value of the specified column as a reader.- Specified by:
getCharacterStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getCharacterStream
Returns the value of the specified column as a reader.- Specified by:
getCharacterStream
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getURL
[Not supported]- Specified by:
getURL
in interfaceResultSet
- Throws:
SQLException
-
getURL
[Not supported]- Specified by:
getURL
in interfaceResultSet
- Throws:
SQLException
-
updateNull
Updates a column in the current or insert row.- Specified by:
updateNull
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Throws:
SQLException
- if the result set is closed or not updatable
-
updateNull
Updates a column in the current or insert row.- Specified by:
updateNull
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBoolean
Updates a column in the current or insert row.- Specified by:
updateBoolean
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBoolean
Updates a column in the current or insert row.- Specified by:
updateBoolean
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if result set is closed or not updatable
-
updateByte
Updates a column in the current or insert row.- Specified by:
updateByte
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateByte
Updates a column in the current or insert row.- Specified by:
updateByte
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBytes
Updates a column in the current or insert row.- Specified by:
updateBytes
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBytes
Updates a column in the current or insert row.- Specified by:
updateBytes
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateShort
Updates a column in the current or insert row.- Specified by:
updateShort
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateShort
Updates a column in the current or insert row.- Specified by:
updateShort
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateInt
Updates a column in the current or insert row.- Specified by:
updateInt
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateInt
Updates a column in the current or insert row.- Specified by:
updateInt
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateLong
Updates a column in the current or insert row.- Specified by:
updateLong
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateLong
Updates a column in the current or insert row.- Specified by:
updateLong
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateFloat
Updates a column in the current or insert row.- Specified by:
updateFloat
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateFloat
Updates a column in the current or insert row.- Specified by:
updateFloat
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateDouble
Updates a column in the current or insert row.- Specified by:
updateDouble
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateDouble
Updates a column in the current or insert row.- Specified by:
updateDouble
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBigDecimal
Updates a column in the current or insert row.- Specified by:
updateBigDecimal
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBigDecimal
Updates a column in the current or insert row.- Specified by:
updateBigDecimal
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateString
Updates a column in the current or insert row.- Specified by:
updateString
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateString
Updates a column in the current or insert row.- Specified by:
updateString
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateDate
Updates a column in the current or insert row.Usage of this method is discouraged. Use
updateObject(columnIndex, value)
withLocalDate
parameter instead.- Specified by:
updateDate
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable- See Also:
-
updateDate
Updates a column in the current or insert row.Usage of this method is discouraged. Use
updateObject(columnLabel, value)
withLocalDate
parameter instead.- Specified by:
updateDate
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable- See Also:
-
updateTime
Updates a column in the current or insert row.Usage of this method is discouraged. Use
updateObject(columnIndex, value)
withLocalTime
parameter instead.- Specified by:
updateTime
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable- See Also:
-
updateTime
Updates a column in the current or insert row.Usage of this method is discouraged. Use
updateObject(columnLabel, value)
withLocalTime
parameter instead.- Specified by:
updateTime
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable- See Also:
-
updateTimestamp
Updates a column in the current or insert row.Usage of this method is discouraged. Use
updateObject(columnIndex, value)
withLocalDateTime
parameter instead.- Specified by:
updateTimestamp
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable- See Also:
-
updateTimestamp
Updates a column in the current or insert row.Usage of this method is discouraged. Use
updateObject(columnLabel, value)
withLocalDateTime
parameter instead.- Specified by:
updateTimestamp
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable- See Also:
-
updateAsciiStream
Updates a column in the current or insert row.- Specified by:
updateAsciiStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
updateAsciiStream
Updates a column in the current or insert row.- Specified by:
updateAsciiStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateAsciiStream
Updates a column in the current or insert row.- Specified by:
updateAsciiStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
updateAsciiStream
Updates a column in the current or insert row.- Specified by:
updateAsciiStream
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
updateAsciiStream
Updates a column in the current or insert row.- Specified by:
updateAsciiStream
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed
-
updateAsciiStream
Updates a column in the current or insert row.- Specified by:
updateAsciiStream
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBinaryStream
Updates a column in the current or insert row.- Specified by:
updateBinaryStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBinaryStream
Updates a column in the current or insert row.- Specified by:
updateBinaryStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBinaryStream
Updates a column in the current or insert row.- Specified by:
updateBinaryStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBinaryStream
Updates a column in the current or insert row.- Specified by:
updateBinaryStream
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBinaryStream
Updates a column in the current or insert row.- Specified by:
updateBinaryStream
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBinaryStream
Updates a column in the current or insert row.- Specified by:
updateBinaryStream
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
updateCharacterStream
Updates a column in the current or insert row.- Specified by:
updateCharacterStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
updateCharacterStream
Updates a column in the current or insert row.- Specified by:
updateCharacterStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
updateCharacterStream
Updates a column in the current or insert row.- Specified by:
updateCharacterStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateCharacterStream
Updates a column in the current or insert row.- Specified by:
updateCharacterStream
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
updateCharacterStream
Updates a column in the current or insert row.- Specified by:
updateCharacterStream
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateCharacterStream
Updates a column in the current or insert row.- Specified by:
updateCharacterStream
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
updateObject
Updates a column in the current or insert row.- Specified by:
updateObject
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the valuescale
- is ignored- Throws:
SQLException
- if the result set is closed or not updatable
-
updateObject
Updates a column in the current or insert row.- Specified by:
updateObject
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the valuescale
- is ignored- Throws:
SQLException
- if the result set is closed or not updatable
-
updateObject
Updates a column in the current or insert row.- Specified by:
updateObject
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateObject
Updates a column in the current or insert row.- Specified by:
updateObject
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateObject
Updates a column in the current or insert row.- Specified by:
updateObject
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the valuetargetSqlType
- the SQL type- Throws:
SQLException
- if the result set is closed or not updatable
-
updateObject
public void updateObject(int columnIndex, Object x, SQLType targetSqlType, int scaleOrLength) throws SQLException Updates a column in the current or insert row.- Specified by:
updateObject
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the valuetargetSqlType
- the SQL typescaleOrLength
- is ignored- Throws:
SQLException
- if the result set is closed or not updatable
-
updateObject
Updates a column in the current or insert row.- Specified by:
updateObject
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the valuetargetSqlType
- the SQL type- Throws:
SQLException
- if the result set is closed or not updatable
-
updateObject
public void updateObject(String columnLabel, Object x, SQLType targetSqlType, int scaleOrLength) throws SQLException Updates a column in the current or insert row.- Specified by:
updateObject
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the valuetargetSqlType
- the SQL typescaleOrLength
- is ignored- Throws:
SQLException
- if the result set is closed or not updatable
-
updateRef
[Not supported]- Specified by:
updateRef
in interfaceResultSet
- Throws:
SQLException
-
updateRef
[Not supported]- Specified by:
updateRef
in interfaceResultSet
- Throws:
SQLException
-
updateBlob
Updates a column in the current or insert row.- Specified by:
updateBlob
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBlob
Updates a column in the current or insert row.- Specified by:
updateBlob
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the valuelength
- the length- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBlob
Updates a column in the current or insert row.- Specified by:
updateBlob
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBlob
Updates a column in the current or insert row.- Specified by:
updateBlob
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBlob
Updates a column in the current or insert row.- Specified by:
updateBlob
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateBlob
Updates a column in the current or insert row.- Specified by:
updateBlob
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the valuelength
- the length- Throws:
SQLException
- if the result set is closed or not updatable
-
updateClob
Updates a column in the current or insert row.- Specified by:
updateClob
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateClob
Updates a column in the current or insert row.- Specified by:
updateClob
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateClob
Updates a column in the current or insert row.- Specified by:
updateClob
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the valuelength
- the length- Throws:
SQLException
- if the result set is closed or not updatable
-
updateClob
Updates a column in the current or insert row.- Specified by:
updateClob
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateClob
Updates a column in the current or insert row.- Specified by:
updateClob
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateClob
Updates a column in the current or insert row.- Specified by:
updateClob
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the valuelength
- the length- Throws:
SQLException
- if the result set is closed or not updatable
-
updateArray
Updates a column in the current or insert row.- Specified by:
updateArray
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateArray
Updates a column in the current or insert row.- Specified by:
updateArray
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
getCursorName
[Not supported] Gets the cursor name if it was defined. This feature is superseded by updateX methods. This method throws a SQLException because cursor names are not supported.- Specified by:
getCursorName
in interfaceResultSet
- Throws:
SQLException
-
getRow
Gets the current row number. The first row is row 1, the second 2 and so on. This method returns 0 before the first and after the last row.- Specified by:
getRow
in interfaceResultSet
- Returns:
- the row number
- Throws:
SQLException
-
getConcurrency
Gets the result set concurrency. Result sets are only updatable if the statement was created with updatable concurrency, and if the result set contains all columns of the primary key or of a unique index of a table.- Specified by:
getConcurrency
in interfaceResultSet
- Returns:
- ResultSet.CONCUR_UPDATABLE if the result set is updatable, or ResultSet.CONCUR_READ_ONLY otherwise
- Throws:
SQLException
-
getFetchDirection
Gets the fetch direction.- Specified by:
getFetchDirection
in interfaceResultSet
- Returns:
- the direction: FETCH_FORWARD
- Throws:
SQLException
-
getFetchSize
Gets the number of rows suggested to read in one step.- Specified by:
getFetchSize
in interfaceResultSet
- Returns:
- the current fetch size
- Throws:
SQLException
-
setFetchSize
Sets the number of rows suggested to read in one step. This value cannot be higher than the maximum rows (setMaxRows) set by the statement or prepared statement, otherwise an exception is throws. Setting the value to 0 will set the default value. The default value can be changed using the system property h2.serverResultSetFetchSize.- Specified by:
setFetchSize
in interfaceResultSet
- Parameters:
rows
- the number of rows- Throws:
SQLException
-
setFetchDirection
[Not supported] Sets (changes) the fetch direction for this result set. This method should only be called for scrollable result sets, otherwise it will throw an exception (no matter what direction is used).- Specified by:
setFetchDirection
in interfaceResultSet
- Parameters:
direction
- the new fetch direction- Throws:
SQLException
- Unsupported Feature if the method is called for a forward-only result set
-
getType
Get the result set type.- Specified by:
getType
in interfaceResultSet
- Returns:
- the result set type (TYPE_FORWARD_ONLY, TYPE_SCROLL_INSENSITIVE or TYPE_SCROLL_SENSITIVE)
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
isBeforeFirst
Checks if the current position is before the first row, that means next() was not called yet, and there is at least one row.- Specified by:
isBeforeFirst
in interfaceResultSet
- Returns:
- if there are results and the current position is before the first row
- Throws:
SQLException
- if the result set is closed
-
isAfterLast
Checks if the current position is after the last row, that means next() was called and returned false, and there was at least one row.- Specified by:
isAfterLast
in interfaceResultSet
- Returns:
- if there are results and the current position is after the last row
- Throws:
SQLException
- if the result set is closed
-
isFirst
Checks if the current position is row 1, that means next() was called once and returned true.- Specified by:
isFirst
in interfaceResultSet
- Returns:
- if the current position is the first row
- Throws:
SQLException
- if the result set is closed
-
isLast
Checks if the current position is the last row, that means next() was called and did not yet returned false, but will in the next call.- Specified by:
isLast
in interfaceResultSet
- Returns:
- if the current position is the last row
- Throws:
SQLException
- if the result set is closed
-
beforeFirst
Moves the current position to before the first row, that means resets the result set.- Specified by:
beforeFirst
in interfaceResultSet
- Throws:
SQLException
- if the result set is closed
-
afterLast
Moves the current position to after the last row, that means after the end.- Specified by:
afterLast
in interfaceResultSet
- Throws:
SQLException
- if the result set is closed
-
first
Moves the current position to the first row. This is the same as calling beforeFirst() followed by next().- Specified by:
first
in interfaceResultSet
- Returns:
- true if there is a row available, false if not
- Throws:
SQLException
- if the result set is closed
-
last
Moves the current position to the last row.- Specified by:
last
in interfaceResultSet
- Returns:
- true if there is a row available, false if not
- Throws:
SQLException
- if the result set is closed
-
absolute
Moves the current position to a specific row.- Specified by:
absolute
in interfaceResultSet
- Parameters:
rowNumber
- the row number. 0 is not allowed, 1 means the first row, 2 the second. -1 means the last row, -2 the row before the last row. If the value is too large, the position is moved after the last row, if the value is too small it is moved before the first row.- Returns:
- true if there is a row available, false if not
- Throws:
SQLException
- if the result set is closed
-
relative
Moves the current position to a specific row relative to the current row.- Specified by:
relative
in interfaceResultSet
- Parameters:
rowCount
- 0 means don't do anything, 1 is the next row, -1 the previous. If the value is too large, the position is moved after the last row, if the value is too small it is moved before the first row.- Returns:
- true if there is a row available, false if not
- Throws:
SQLException
- if the result set is closed
-
previous
Moves the cursor to the last row, or row before first row if the current position is the first row.- Specified by:
previous
in interfaceResultSet
- Returns:
- true if there is a row available, false if not
- Throws:
SQLException
- if the result set is closed
-
moveToInsertRow
Moves the current position to the insert row. The current row is remembered.- Specified by:
moveToInsertRow
in interfaceResultSet
- Throws:
SQLException
- if the result set is closed or is not updatable
-
moveToCurrentRow
Moves the current position to the current row.- Specified by:
moveToCurrentRow
in interfaceResultSet
- Throws:
SQLException
- if the result set is closed or is not updatable
-
rowUpdated
Detects if the row was updated (by somebody else or the caller).- Specified by:
rowUpdated
in interfaceResultSet
- Returns:
- false because this driver does not detect this
- Throws:
SQLException
-
rowInserted
Detects if the row was inserted.- Specified by:
rowInserted
in interfaceResultSet
- Returns:
- false because this driver does not detect this
- Throws:
SQLException
-
rowDeleted
Detects if the row was deleted (by somebody else or the caller).- Specified by:
rowDeleted
in interfaceResultSet
- Returns:
- false because this driver does not detect this
- Throws:
SQLException
-
insertRow
Inserts the current row. The current position must be the insert row.- Specified by:
insertRow
in interfaceResultSet
- Throws:
SQLException
- if the result set is closed or if not on the insert row, or if the result set it not updatable
-
updateRow
Updates the current row.- Specified by:
updateRow
in interfaceResultSet
- Throws:
SQLException
- if the result set is closed, if the current row is the insert row or if not on a valid row, or if the result set it not updatable
-
deleteRow
Deletes the current row.- Specified by:
deleteRow
in interfaceResultSet
- Throws:
SQLException
- if the result set is closed, if the current row is the insert row or if not on a valid row, or if the result set it not updatable
-
refreshRow
Re-reads the current row from the database.- Specified by:
refreshRow
in interfaceResultSet
- Throws:
SQLException
- if the result set is closed or if the current row is the insert row or if the row has been deleted or if not on a valid row
-
cancelRowUpdates
Cancels updating a row.- Specified by:
cancelRowUpdates
in interfaceResultSet
- Throws:
SQLException
- if the result set is closed or if the current row is the insert row
-
getInternal
public org.h2.value.Value getInternal(int columnIndex) INTERNAL- Parameters:
columnIndex
- index of a column- Returns:
- internal representation of the value in the specified column
-
getRowId
[Not supported] Returns the value of the specified column as a row id.- Specified by:
getRowId
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Throws:
SQLException
-
getRowId
[Not supported] Returns the value of the specified column as a row id.- Specified by:
getRowId
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Throws:
SQLException
-
updateRowId
[Not supported] Updates a column in the current or insert row.- Specified by:
updateRowId
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
-
updateRowId
[Not supported] Updates a column in the current or insert row.- Specified by:
updateRowId
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
-
getHoldability
Returns the current result set holdability.- Specified by:
getHoldability
in interfaceResultSet
- Returns:
- the holdability
- Throws:
SQLException
- if the connection is closed
-
isClosed
Returns whether this result set is closed.- Specified by:
isClosed
in interfaceResultSet
- Returns:
- true if the result set is closed
- Throws:
SQLException
-
updateNString
Updates a column in the current or insert row.- Specified by:
updateNString
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateNString
Updates a column in the current or insert row.- Specified by:
updateNString
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateNClob
Updates a column in the current or insert row.- Specified by:
updateNClob
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateNClob
Updates a column in the current or insert row.- Specified by:
updateNClob
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateNClob
Updates a column in the current or insert row.- Specified by:
updateNClob
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the valuelength
- the length- Throws:
SQLException
- if the result set is closed or not updatable
-
updateNClob
Updates a column in the current or insert row.- Specified by:
updateNClob
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateNClob
Updates a column in the current or insert row.- Specified by:
updateNClob
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the valuelength
- the length- Throws:
SQLException
- if the result set is closed or not updatable
-
updateNClob
Updates a column in the current or insert row.- Specified by:
updateNClob
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
getNClob
Returns the value of the specified column as a Clob.- Specified by:
getNClob
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getNClob
Returns the value of the specified column as a Clob.- Specified by:
getNClob
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getSQLXML
Returns the value of the specified column as a SQLXML.- Specified by:
getSQLXML
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getSQLXML
Returns the value of the specified column as a SQLXML.- Specified by:
getSQLXML
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
updateSQLXML
Updates a column in the current or insert row.- Specified by:
updateSQLXML
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)xmlObject
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateSQLXML
Updates a column in the current or insert row.- Specified by:
updateSQLXML
in interfaceResultSet
- Parameters:
columnLabel
- the column labelxmlObject
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
getNString
Returns the value of the specified column as a String.- Specified by:
getNString
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getNString
Returns the value of the specified column as a String.- Specified by:
getNString
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getNCharacterStream
Returns the value of the specified column as a reader.- Specified by:
getNCharacterStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getNCharacterStream
Returns the value of the specified column as a reader.- Specified by:
getNCharacterStream
in interfaceResultSet
- Parameters:
columnLabel
- the column label- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
updateNCharacterStream
Updates a column in the current or insert row.- Specified by:
updateNCharacterStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateNCharacterStream
Updates a column in the current or insert row.- Specified by:
updateNCharacterStream
in interfaceResultSet
- Parameters:
columnIndex
- (1,2,...)x
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
updateNCharacterStream
Updates a column in the current or insert row.- Specified by:
updateNCharacterStream
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the value- Throws:
SQLException
- if the result set is closed or not updatable
-
updateNCharacterStream
Updates a column in the current or insert row.- Specified by:
updateNCharacterStream
in interfaceResultSet
- Parameters:
columnLabel
- the column labelx
- the valuelength
- the number of characters- Throws:
SQLException
- if the result set is closed or not updatable
-
unwrap
Return an object of this class if possible.- Specified by:
unwrap
in interfaceWrapper
- Parameters:
iface
- the class- Returns:
- this
- Throws:
SQLException
-
isWrapperFor
Checks if unwrap can return an object of this class.- Specified by:
isWrapperFor
in interfaceWrapper
- Parameters:
iface
- the class- Returns:
- whether or not the interface is assignable from this class
- Throws:
SQLException
-
getObject
Returns a column value as a Java object of the specified type.- Specified by:
getObject
in interfaceResultSet
- Parameters:
columnIndex
- the column index (1, 2, ...)type
- the class of the returned value- Returns:
- the value
- Throws:
SQLException
- if the column is not found or if the result set is closed
-
getObject
Returns a column value as a Java object of the specified type.- Specified by:
getObject
in interfaceResultSet
- Parameters:
columnName
- the column nametype
- the class of the returned value- Returns:
- the value
- Throws:
SQLException
-
toString
INTERNAL -
getUpdateRow
public org.h2.value.Value[] getUpdateRow()INTERNAL- Returns:
- array of column values for the current row
-
getResult
public org.h2.result.ResultInterface getResult()INTERNAL- Returns:
- result
-
getBigDecimal(int)