Statement
This class models a cursor, which can be stepped through one row at a
time. Methods are provided for accessing columns by column name or by
index.
Note that a result set is invalidated if the statement that returned
it is closed.
Method Summary |
abstract boolean |
absolute(int row)
This method positions the result set to the specified absolute row.
|
abstract void |
afterLast()
This method repositions the cursor to after the last row in the result
set. |
abstract void |
beforeFirst()
This method repositions the cursor to before the first row in the
result set. |
abstract void |
cancelRowUpdates()
This method cancels any changes that have been made to a row. |
abstract void |
clearWarnings()
This method clears all warnings associated with this result set. |
abstract void |
close()
This method closes the result set and frees any associated resources. |
abstract void |
deleteRow()
This method deletes the current row in the database. |
abstract int |
findColumn(String columnName)
This method returns the column index of the specified named column. |
abstract boolean |
first()
This method repositions the cursor on the first row in the
result set. |
abstract Blob |
getBlob(int i)
This method returns the specified column value as a BLOB. |
abstract Blob |
getBlob(String colName)
This method returns the specified column value as a BLOB. |
abstract boolean |
getBoolean(int columnIndex)
This method returns the value of the specified column as a Java
boolean . |
abstract boolean |
getBoolean(String columnName)
This method returns the value of the specified column as a Java
boolean . |
abstract byte |
getByte(int columnIndex)
This method returns the value of the specified column as a Java
byte . |
abstract byte |
getByte(String columnName)
This method returns the value of the specified column as a Java
byte . |
abstract byte[] |
getBytes(int columnIndex)
This method returns the value of the specified column as a Java
byte array. |
abstract byte[] |
getBytes(String columnName)
This method returns the value of the specified column as a Java
byte array. |
abstract int |
getConcurrency()
This method returns the concurrency type of this result set. |
abstract String |
getCursorName()
This method returns the name of the database cursor used by this
result set. |
abstract Date |
getDate(int columnIndex)
This method returns the value of the specified column as a Java
java.sql.Date . |
abstract Date |
getDate(String columnName)
This method returns the value of the specified column as a Java
java.sql.Date . |
abstract double |
getDouble(int columnIndex)
This method returns the value of the specified column as a Java
double . |
abstract double |
getDouble(String columnName)
This method returns the value of the specified column as a Java
double . |
abstract int |
getFetchDirection()
This method returns the current fetch direction for this result set. |
abstract int |
getFetchSize()
This method returns the current number of rows that will be fetched
from the database at a time. |
abstract float |
getFloat(int columnIndex)
This method returns the value of the specified column as a Java
float . |
abstract float |
getFloat(String columnName)
This method returns the value of the specified column as a Java
float . |
abstract int |
getInt(int columnIndex)
This method returns the value of the specified column as a Java
int . |
abstract int |
getInt(String columnName)
This method returns the value of the specified column as a Java
int . |
abstract long |
getLong(int columnIndex)
This method returns the value of the specified column as a Java
long . |
abstract long |
getLong(String columnName)
This method returns the value of the specified column as a Java
long . |
abstract ResultSetMetaData |
getMetaData()
This method returns data about the columns returned as part of the
result set as a ResultSetMetaData instance. |
abstract Object |
getObject(int columnIndex)
This method returns the value of the specified column as a Java
Object . |
abstract Object |
getObject(String columnName)
This method returns the value of the specified column as a Java
Object . |
abstract Ref |
getRef(int i)
This method returns a Ref for the specified column which
represents the structured type for the column. |
abstract Ref |
getRef(String colName)
This method returns a Ref for the specified column which
represents the structured type for the column. |
abstract int |
getRow()
This method returns the current row number in the cursor. |
abstract short |
getShort(int columnIndex)
This method returns the value of the specified column as a Java
short . |
abstract short |
getShort(String columnName)
This method returns the value of the specified column as a Java
short . |
abstract Statement |
getStatement()
This method returns a the Statement that was used to
produce this result set. |
abstract String |
getString(int columnIndex)
This method returns the value of the specified column as a Java
String . |
abstract String |
getString(String columnName)
This method returns the value of the specified column as a Java
String . |
abstract Time |
getTime(int columnIndex)
This method returns the value of the specified column as a Java
java.sql.Time . |
abstract Time |
getTime(String columnName)
This method returns the value of the specified column as a Java
java.sql.Time . |
abstract Timestamp |
getTimestamp(int columnIndex)
This method returns the value of the specified column as a Java
java.sql.Timestamp . |
abstract Timestamp |
getTimestamp(String columnName)
This method returns the value of the specified column as a Java
java.sql.Timestamp . |
abstract int |
getType()
This method returns the result set type of this result set. |
abstract SQLWarning |
getWarnings()
This method returns the first SQL warning associated with this result
set. |
abstract void |
insertRow()
This method inserts the current row into the database. |
abstract boolean |
isAfterLast()
This method tests whether or not the cursor is after the last row
in the result set. |
abstract boolean |
isBeforeFirst()
This method tests whether or not the cursor is before the first row
in the result set. |
abstract boolean |
isFirst()
This method tests whether or not the cursor is positioned on the first
row in the result set. |
abstract boolean |
isLast()
This method tests whether or not the cursor is on the last row
in the result set. |
abstract boolean |
last()
This method repositions the cursor on the last row in the result
set. |
abstract void |
moveToCurrentRow()
This method moves the result set position from the insert row back to
the current row that was selected prior to moving to the insert row. |
abstract void |
moveToInsertRow()
This method positions the result set to the "insert row", which allows
a new row to be inserted into the database from the result set. |
abstract boolean |
next()
This method advances to the next row in the result set. |
abstract boolean |
previous()
This method moves the current position to the previous row in the
result set. |
abstract void |
refreshRow()
This method refreshes the contents of the current row from the database. |
abstract boolean |
relative(int rows)
This method moves the result set position relative to the current row.
|
abstract boolean |
rowDeleted()
This method tests whether or not the current row in the result set
has been deleted. |
abstract boolean |
rowInserted()
This method tests whether or not the current row in the result set
has been inserted. |
abstract boolean |
rowUpdated()
This method tests whether or not the current row in the result set
has been updated. |
abstract void |
setFetchDirection(int direction)
This method provides a hint to the driver about which direction the
result set will be processed in. |
abstract void |
setFetchSize(int rows)
This method provides a hint to the driver about how many rows at a
time it should fetch from the database. |
abstract void |
updateBlob(int columnIndex,
Blob x)
|
abstract void |
updateBlob(String columnName,
Blob x)
|
abstract void |
updateBoolean(int columnIndex,
boolean x)
This method updates the specified column to have a boolean value. |
abstract void |
updateBoolean(String columnName,
boolean x)
This method updates the specified column to have a boolean value. |
abstract void |
updateByte(int columnIndex,
byte x)
This method updates the specified column to have a byte value. |
abstract void |
updateByte(String columnName,
byte x)
This method updates the specified column to have a byte value. |
abstract void |
updateBytes(int columnIndex,
byte[] x)
This method updates the specified column to have a byte array value. |
abstract void |
updateBytes(String columnName,
byte[] x)
This method updates the specified column to have a byte array value. |
abstract void |
updateDate(int columnIndex,
Date x)
This method updates the specified column to have a java.sql.Date value. |
abstract void |
updateDate(String columnName,
Date x)
This method updates the specified column to have a java.sql.Date value. |
abstract void |
updateDouble(int columnIndex,
double x)
This method updates the specified column to have a double value. |
abstract void |
updateDouble(String columnName,
double x)
This method updates the specified column to have a double value. |
abstract void |
updateFloat(int columnIndex,
float x)
This method updates the specified column to have a float value. |
abstract void |
updateFloat(String columnName,
float x)
This method updates the specified column to have a float value. |
abstract void |
updateInt(int columnIndex,
int x)
This method updates the specified column to have an int value. |
abstract void |
updateInt(String columnName,
int x)
This method updates the specified column to have an int value. |
abstract void |
updateLong(int columnIndex,
long x)
This method updates the specified column to have a long value. |
abstract void |
updateLong(String columnName,
long x)
This method updates the specified column to have a long value. |
abstract void |
updateNull(int columnIndex)
This method updates the specified column to have a NULL value. |
abstract void |
updateNull(String columnName)
This method updates the specified column to have a NULL value. |
abstract void |
updateObject(int columnIndex,
Object x)
This method updates the specified column to have an Object value.
|
abstract void |
updateObject(int columnIndex,
Object x,
int scale)
This method updates the specified column to have an Object value.
|
abstract void |
updateObject(String columnName,
Object x)
This method updates the specified column to have an Object value.
|
abstract void |
updateObject(String columnName,
Object x,
int scale)
This method updates the specified column to have an Object value.
|
abstract void |
updateRef(int columnIndex,
Ref x)
NOTE: removed from SW |
abstract void |
updateRef(String columnName,
Ref x)
NOTE: removed from SW |
abstract void |
updateRow()
This method updates the current row in the database. |
abstract void |
updateShort(int columnIndex,
short x)
This method updates the specified column to have a short value. |
abstract void |
updateShort(String columnName,
short x)
This method updates the specified column to have a short value. |
abstract void |
updateString(int columnIndex,
String x)
This method updates the specified column to have a String value. |
abstract void |
updateString(String columnName,
String x)
This method updates the specified column to have a String value. |
abstract void |
updateTime(int columnIndex,
Time x)
This method updates the specified column to have a java.sql.Time value. |
abstract void |
updateTime(String columnName,
Time x)
This method updates the specified column to have a java.sql.Time value. |
abstract void |
updateTimestamp(int columnIndex,
Timestamp x)
This method updates the specified column to have a java.sql.Timestamp value.
|
abstract void |
updateTimestamp(String columnName,
Timestamp x)
This method updates the specified column to have a java.sql.Timestamp value.
|
abstract boolean |
wasNull()
This method tests whether the value of the last column that was fetched
was actually a SQL NULL value. |
FETCH_FORWARD
public static final int FETCH_FORWARD
- The rows will be processed in order from first to last.
FETCH_REVERSE
public static final int FETCH_REVERSE
- The rows will be processed in order from last to first.
FETCH_UNKNOWN
public static final int FETCH_UNKNOWN
- The rows will be processed in an unknown order
TYPE_FORWARD_ONLY
public static final int TYPE_FORWARD_ONLY
- This type of result set may only step forward through the rows returned.
TYPE_SCROLL_INSENSITIVE
public static final int TYPE_SCROLL_INSENSITIVE
- This type of result set is scrollable and is not sensitive to changes
made by other statements.
TYPE_SCROLL_SENSITIVE
public static final int TYPE_SCROLL_SENSITIVE
- This type of result set is scrollable and is also sensitive to changes
made by other statements.
CONCUR_READ_ONLY
public static final int CONCUR_READ_ONLY
- The concurrency mode of for the result set may not be modified.
CONCUR_UPDATABLE
public static final int CONCUR_UPDATABLE
- The concurrency mode of for the result set may be modified.
HOLD_CURSORS_OVER_COMMIT
public static final int HOLD_CURSORS_OVER_COMMIT
CLOSE_CURSORS_AT_COMMIT
public static final int CLOSE_CURSORS_AT_COMMIT
ResultSet
public ResultSet()
next
public abstract boolean next()
throws SQLException
- This method advances to the next row in the result set. Any streams
open on the current row are closed automatically.
- Returns:
true
if the next row exists, false
otherwise.- Throws:
- SQLException - If an error occurs.
close
public abstract void close()
throws SQLException
- This method closes the result set and frees any associated resources.
- Throws:
- SQLException - If an error occurs.
wasNull
public abstract boolean wasNull()
throws SQLException
- This method tests whether the value of the last column that was fetched
was actually a SQL NULL value.
- Returns:
true
if the last column fetched was a NULL,
false
otherwise.- Throws:
- SQLException - If an error occurs.
getString
public abstract String getString(int columnIndex)
throws SQLException
- This method returns the value of the specified column as a Java
String
.
- Parameters:
index
- The index of the column to return.- Returns:
- The column value as a
String
. - Throws:
- SQLException - If an error occurs.
getBoolean
public abstract boolean getBoolean(int columnIndex)
throws SQLException
- This method returns the value of the specified column as a Java
boolean
.
- Parameters:
index
- The index of the column to return.- Returns:
- The column value as a
boolean
. - Throws:
- SQLException - If an error occurs.
getByte
public abstract byte getByte(int columnIndex)
throws SQLException
- This method returns the value of the specified column as a Java
byte
.
- Parameters:
index
- The index of the column to return.- Returns:
- The column value as a
byte
. - Throws:
- SQLException - If an error occurs.
getShort
public abstract short getShort(int columnIndex)
throws SQLException
- This method returns the value of the specified column as a Java
short
.
- Parameters:
index
- The index of the column to return.- Returns:
- The column value as a
short
. - Throws:
- SQLException - If an error occurs.
getInt
public abstract int getInt(int columnIndex)
throws SQLException
- This method returns the value of the specified column as a Java
int
.
- Parameters:
index
- The index of the column to return.- Returns:
- The column value as a
int
. - Throws:
- SQLException - If an error occurs.
getLong
public abstract long getLong(int columnIndex)
throws SQLException
- This method returns the value of the specified column as a Java
long
.
- Parameters:
index
- The index of the column to return.- Returns:
- The column value as a
long
. - Throws:
- SQLException - If an error occurs.
getFloat
public abstract float getFloat(int columnIndex)
throws SQLException
- This method returns the value of the specified column as a Java
float
.
- Parameters:
index
- The index of the column to return.- Returns:
- The column value as a
float
. - Throws:
- SQLException - If an error occurs.
getDouble
public abstract double getDouble(int columnIndex)
throws SQLException
- This method returns the value of the specified column as a Java
double
.
- Parameters:
index
- The index of the column to return.- Returns:
- The column value as a
double
. - Throws:
- SQLException - If an error occurs.
getBytes
public abstract byte[] getBytes(int columnIndex)
throws SQLException
- This method returns the value of the specified column as a Java
byte array.
- Parameters:
index
- The index of the column to return.- Returns:
- The column value as a byte array
- Throws:
- SQLException - If an error occurs.
getDate
public abstract Date getDate(int columnIndex)
throws SQLException
- This method returns the value of the specified column as a Java
java.sql.Date
.
- Parameters:
index
- The index of the column to return.- Returns:
- The column value as a
java.sql.Date
. - Throws:
- SQLException - If an error occurs.
getTime
public abstract Time getTime(int columnIndex)
throws SQLException
- This method returns the value of the specified column as a Java
java.sql.Time
.
- Parameters:
index
- The index of the column to return.- Returns:
- The column value as a
java.sql.Time
. - Throws:
- SQLException - If an error occurs.
getTimestamp
public abstract Timestamp getTimestamp(int columnIndex)
throws SQLException
- This method returns the value of the specified column as a Java
java.sql.Timestamp
.
- Parameters:
index
- The index of the column to return.- Returns:
- The column value as a
java.sql.Timestamp
. - Throws:
- SQLException - If an error occurs.
getString
public abstract String getString(String columnName)
throws SQLException
- This method returns the value of the specified column as a Java
String
.
- Parameters:
column
- The name of the column to return.- Returns:
- The column value as a
String
. - Throws:
- SQLException - If an error occurs.
getBoolean
public abstract boolean getBoolean(String columnName)
throws SQLException
- This method returns the value of the specified column as a Java
boolean
.
- Parameters:
column
- The name of the column to return.- Returns:
- The column value as a
boolean
. - Throws:
- SQLException - If an error occurs.
getByte
public abstract byte getByte(String columnName)
throws SQLException
- This method returns the value of the specified column as a Java
byte
.
- Parameters:
column
- The name of the column to return.- Returns:
- The column value as a
byte
. - Throws:
- SQLException - If an error occurs.
getShort
public abstract short getShort(String columnName)
throws SQLException
- This method returns the value of the specified column as a Java
short
.
- Parameters:
column
- The name of the column to return.- Returns:
- The column value as a
short
. - Throws:
- SQLException - If an error occurs.
getInt
public abstract int getInt(String columnName)
throws SQLException
- This method returns the value of the specified column as a Java
int
.
- Parameters:
column
- The name of the column to return.- Returns:
- The column value as a
int
. - Throws:
- SQLException - If an error occurs.
getLong
public abstract long getLong(String columnName)
throws SQLException
- This method returns the value of the specified column as a Java
long
.
- Parameters:
column
- The name of the column to return.- Returns:
- The column value as a
long
. - Throws:
- SQLException - If an error occurs.
getFloat
public abstract float getFloat(String columnName)
throws SQLException
- This method returns the value of the specified column as a Java
float
.
- Parameters:
column
- The name of the column to return.- Returns:
- The column value as a
float
. - Throws:
- SQLException - If an error occurs.
getDouble
public abstract double getDouble(String columnName)
throws SQLException
- This method returns the value of the specified column as a Java
double
.
- Parameters:
column
- The name of the column to return.- Returns:
- The column value as a
double
. - Throws:
- SQLException - If an error occurs.
getBytes
public abstract byte[] getBytes(String columnName)
throws SQLException
- This method returns the value of the specified column as a Java
byte array.
- Parameters:
column
- The name of the column to return.- Returns:
- The column value as a byte array
- Throws:
- SQLException - If an error occurs.
getDate
public abstract Date getDate(String columnName)
throws SQLException
- This method returns the value of the specified column as a Java
java.sql.Date
.
- Parameters:
column
- The name of the column to return.- Returns:
- The column value as a
java.sql.Date
. - Throws:
- SQLException - If an error occurs.
getTime
public abstract Time getTime(String columnName)
throws SQLException
- This method returns the value of the specified column as a Java
java.sql.Time
.
- Parameters:
column
- The name of the column to return.- Returns:
- The column value as a
java.sql.Time
. - Throws:
- SQLException - If an error occurs.
getTimestamp
public abstract Timestamp getTimestamp(String columnName)
throws SQLException
- This method returns the value of the specified column as a Java
java.sql.Timestamp
.
- Parameters:
column
- The name of the column to return.- Returns:
- The column value as a
java.sql.Timestamp
. - Throws:
- SQLException - If an error occurs.
getWarnings
public abstract SQLWarning getWarnings()
throws SQLException
- This method returns the first SQL warning associated with this result
set. Any additional warnings will be chained to this one.
- Returns:
- The first SQLWarning for this result set, or
null
if
there are no warnings. - Throws:
- SQLException - If an error occurs.
clearWarnings
public abstract void clearWarnings()
throws SQLException
- This method clears all warnings associated with this result set.
- Throws:
- SQLException - If an error occurs.
getCursorName
public abstract String getCursorName()
throws SQLException
- This method returns the name of the database cursor used by this
result set.
- Returns:
- The name of the database cursor used by this result set.
- Throws:
- SQLException - If an error occurs.
getMetaData
public abstract ResultSetMetaData getMetaData()
throws SQLException
- This method returns data about the columns returned as part of the
result set as a
ResultSetMetaData
instance.
- Returns:
- The
ResultSetMetaData
instance for this result set. - Throws:
- SQLException - If an error occurs.
getObject
public abstract Object getObject(int columnIndex)
throws SQLException
- This method returns the value of the specified column as a Java
Object
.
- Parameters:
index
- The index of the column to return.- Returns:
- The column value as an
Object
. - Throws:
- SQLException - If an error occurs.
getObject
public abstract Object getObject(String columnName)
throws SQLException
- This method returns the value of the specified column as a Java
Object
.
- Parameters:
column
- The name of the column to return.- Returns:
- The column value as an
Object
. - Throws:
- SQLException - If an error occurs.
findColumn
public abstract int findColumn(String columnName)
throws SQLException
- This method returns the column index of the specified named column.
- Parameters:
column
- The name of the column.- Returns:
- The index of the column.
- Throws:
- SQLException - If an error occurs.
isBeforeFirst
public abstract boolean isBeforeFirst()
throws SQLException
- This method tests whether or not the cursor is before the first row
in the result set.
- Returns:
true
if the cursor is positioned before the first
row, false
otherwise.- Throws:
- SQLException - If an error occurs.
isAfterLast
public abstract boolean isAfterLast()
throws SQLException
- This method tests whether or not the cursor is after the last row
in the result set.
- Returns:
true
if the cursor is positioned after the last
row, false
otherwise.- Throws:
- SQLException - If an error occurs.
isFirst
public abstract boolean isFirst()
throws SQLException
- This method tests whether or not the cursor is positioned on the first
row in the result set.
- Returns:
true
if the cursor is positioned on the first
row, false
otherwise.- Throws:
- SQLException - If an error occurs.
isLast
public abstract boolean isLast()
throws SQLException
- This method tests whether or not the cursor is on the last row
in the result set.
- Returns:
true
if the cursor is positioned on the last
row, false
otherwise.- Throws:
- SQLException - If an error occurs.
beforeFirst
public abstract void beforeFirst()
throws SQLException
- This method repositions the cursor to before the first row in the
result set.
- Throws:
- SQLException - If an error occurs.
afterLast
public abstract void afterLast()
throws SQLException
- This method repositions the cursor to after the last row in the result
set.
- Throws:
- SQLException - If an error occurs.
first
public abstract boolean first()
throws SQLException
- This method repositions the cursor on the first row in the
result set.
- Returns:
true
if the cursor is on a valid row;
false
if there are no rows in the result set.- Throws:
- SQLException - If an error occurs.
last
public abstract boolean last()
throws SQLException
- This method repositions the cursor on the last row in the result
set.
- Returns:
true
if the cursor is on a valid row;
false
if there are no rows in the result set.- Throws:
- SQLException - If an error occurs.
getRow
public abstract int getRow()
throws SQLException
- This method returns the current row number in the cursor. Numbering
begins at index 1.
- Returns:
- The current row number, or 0 if there is not current row.
- Throws:
- SQLException - If an error occurs.
absolute
public abstract boolean absolute(int row)
throws SQLException
- This method positions the result set to the specified absolute row.
Positive numbers are row offsets from the beginning of the result
set (numbering starts from row 1) and negative numbers are row offsets
from the end of the result set (numbering starts from -1).
- Parameters:
row
- The row to position the result set to.- Returns:
true
if the current position was changed,
false
otherwise.- Throws:
- SQLException - If an error occurs.
relative
public abstract boolean relative(int rows)
throws SQLException
- This method moves the result set position relative to the current row.
The offset can be positive or negative.
- Parameters:
row
- The relative row position to move to.- Returns:
true
if the current position was changed,
false
otherwise.- Throws:
- SQLException - If an error occurs.
previous
public abstract boolean previous()
throws SQLException
- This method moves the current position to the previous row in the
result set.
- Returns:
true
if the previous row exists, false
otherwise.- Throws:
- SQLException - If an error occurs.
setFetchDirection
public abstract void setFetchDirection(int direction)
throws SQLException
- This method provides a hint to the driver about which direction the
result set will be processed in.
- Parameters:
direction
- The direction in which rows will be processed. (Values?)- Throws:
- SQLException - If an error occurs.
getFetchDirection
public abstract int getFetchDirection()
throws SQLException
- This method returns the current fetch direction for this result set.
- Returns:
- The fetch direction for this result set.
- Throws:
- SQLException - If an error occurs.
setFetchSize
public abstract void setFetchSize(int rows)
throws SQLException
- This method provides a hint to the driver about how many rows at a
time it should fetch from the database.
- Parameters:
rows
- The number of rows the driver should fetch per call.- Throws:
- SQLException - If an error occurs.
getFetchSize
public abstract int getFetchSize()
throws SQLException
- This method returns the current number of rows that will be fetched
from the database at a time.
- Returns:
- The current fetch size for this result set.
- Throws:
- SQLException - If an error occurs.
getType
public abstract int getType()
throws SQLException
- This method returns the result set type of this result set. This will
be one of the TYPE_* constants defined in this interface.
- Returns:
- The result set type.
- Throws:
- SQLException - If an error occurs.
getConcurrency
public abstract int getConcurrency()
throws SQLException
- This method returns the concurrency type of this result set. This will
be one of the CONCUR_* constants defined in this interface.
- Returns:
- The result set concurrency type.
- Throws:
- SQLException - If an error occurs.
rowUpdated
public abstract boolean rowUpdated()
throws SQLException
- This method tests whether or not the current row in the result set
has been updated. Updates must be visible in order of this method to
detect the update.
- Returns:
true
if the row has been updated, false
otherwise.- Throws:
- SQLException - If an error occurs.
rowInserted
public abstract boolean rowInserted()
throws SQLException
- This method tests whether or not the current row in the result set
has been inserted. Inserts must be visible in order of this method to
detect the insert.
- Returns:
true
if the row has been inserted, false
otherwise.- Throws:
- SQLException - If an error occurs.
rowDeleted
public abstract boolean rowDeleted()
throws SQLException
- This method tests whether or not the current row in the result set
has been deleted. Deletes must be visible in order of this method to
detect the deletion.
- Returns:
true
if the row has been deleted, false
otherwise.- Throws:
- SQLException - If an error occurs.
updateNull
public abstract void updateNull(int columnIndex)
throws SQLException
- This method updates the specified column to have a NULL value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Returns:
- index The index of the column to update.
- Throws:
- SQLException - If an error occurs.
updateBoolean
public abstract void updateBoolean(int columnIndex,
boolean x)
throws SQLException
- This method updates the specified column to have a boolean value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateByte
public abstract void updateByte(int columnIndex,
byte x)
throws SQLException
- This method updates the specified column to have a byte value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateShort
public abstract void updateShort(int columnIndex,
short x)
throws SQLException
- This method updates the specified column to have a short value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateInt
public abstract void updateInt(int columnIndex,
int x)
throws SQLException
- This method updates the specified column to have an int value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateLong
public abstract void updateLong(int columnIndex,
long x)
throws SQLException
- This method updates the specified column to have a long value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateFloat
public abstract void updateFloat(int columnIndex,
float x)
throws SQLException
- This method updates the specified column to have a float value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateDouble
public abstract void updateDouble(int columnIndex,
double x)
throws SQLException
- This method updates the specified column to have a double value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateString
public abstract void updateString(int columnIndex,
String x)
throws SQLException
- This method updates the specified column to have a String value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateBytes
public abstract void updateBytes(int columnIndex,
byte[] x)
throws SQLException
- This method updates the specified column to have a byte array value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateDate
public abstract void updateDate(int columnIndex,
Date x)
throws SQLException
- This method updates the specified column to have a java.sql.Date value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateTime
public abstract void updateTime(int columnIndex,
Time x)
throws SQLException
- This method updates the specified column to have a java.sql.Time value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateTimestamp
public abstract void updateTimestamp(int columnIndex,
Timestamp x)
throws SQLException
- This method updates the specified column to have a java.sql.Timestamp value.
This does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateObject
public abstract void updateObject(int columnIndex,
Object x,
int scale)
throws SQLException
- This method updates the specified column to have an Object value.
This does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateObject
public abstract void updateObject(int columnIndex,
Object x)
throws SQLException
- This method updates the specified column to have an Object value.
This does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
index
- The index of the column to update.value
- The new value of the column.scale
- The scale of the object in question, which is used only
for numeric type objects.- Throws:
- SQLException - If an error occurs.
updateNull
public abstract void updateNull(String columnName)
throws SQLException
- This method updates the specified column to have a NULL value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Returns:
- name The name of the column to update.
- Throws:
- SQLException - If an error occurs.
updateBoolean
public abstract void updateBoolean(String columnName,
boolean x)
throws SQLException
- This method updates the specified column to have a boolean value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateByte
public abstract void updateByte(String columnName,
byte x)
throws SQLException
- This method updates the specified column to have a byte value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateShort
public abstract void updateShort(String columnName,
short x)
throws SQLException
- This method updates the specified column to have a short value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateInt
public abstract void updateInt(String columnName,
int x)
throws SQLException
- This method updates the specified column to have an int value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateLong
public abstract void updateLong(String columnName,
long x)
throws SQLException
- This method updates the specified column to have a long value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateFloat
public abstract void updateFloat(String columnName,
float x)
throws SQLException
- This method updates the specified column to have a float value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateDouble
public abstract void updateDouble(String columnName,
double x)
throws SQLException
- This method updates the specified column to have a double value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateString
public abstract void updateString(String columnName,
String x)
throws SQLException
- This method updates the specified column to have a String value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateBytes
public abstract void updateBytes(String columnName,
byte[] x)
throws SQLException
- This method updates the specified column to have a byte array value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateDate
public abstract void updateDate(String columnName,
Date x)
throws SQLException
- This method updates the specified column to have a java.sql.Date value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateTime
public abstract void updateTime(String columnName,
Time x)
throws SQLException
- This method updates the specified column to have a java.sql.Time value. This
does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateTimestamp
public abstract void updateTimestamp(String columnName,
Timestamp x)
throws SQLException
- This method updates the specified column to have a java.sql.Timestamp value.
This does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateObject
public abstract void updateObject(String columnName,
Object x,
int scale)
throws SQLException
- This method updates the specified column to have an Object value.
This does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.- Throws:
- SQLException - If an error occurs.
updateObject
public abstract void updateObject(String columnName,
Object x)
throws SQLException
- This method updates the specified column to have an Object value.
This does not update the actual database.
updateRow
must be
called in order to do that.
- Parameters:
name
- The name of the column to update.value
- The new value of the column.scale
- The scale of the object in question, which is used only
for numeric type objects.- Throws:
- SQLException - If an error occurs.
insertRow
public abstract void insertRow()
throws SQLException
- This method inserts the current row into the database. The result set
must be positioned on the insert row in order to call this method
successfully.
- Throws:
- SQLException - If an error occurs.
updateRow
public abstract void updateRow()
throws SQLException
- This method updates the current row in the database.
- Throws:
- SQLException - If an error occurs.
deleteRow
public abstract void deleteRow()
throws SQLException
- This method deletes the current row in the database.
- Throws:
- SQLException - If an error occurs.
refreshRow
public abstract void refreshRow()
throws SQLException
- This method refreshes the contents of the current row from the database.
- Throws:
- SQLException - If an error occurs.
cancelRowUpdates
public abstract void cancelRowUpdates()
throws SQLException
- This method cancels any changes that have been made to a row. If
the
rowUpdate
method has been called, then the changes
cannot be undone.
- Throws:
- SQLException - If an error occurs.
moveToInsertRow
public abstract void moveToInsertRow()
throws SQLException
- This method positions the result set to the "insert row", which allows
a new row to be inserted into the database from the result set.
- Throws:
- SQLException - If an error occurs.
moveToCurrentRow
public abstract void moveToCurrentRow()
throws SQLException
- This method moves the result set position from the insert row back to
the current row that was selected prior to moving to the insert row.
- Throws:
- SQLException - If an error occurs.
getStatement
public abstract Statement getStatement()
throws SQLException
- This method returns a the
Statement
that was used to
produce this result set.
- Returns:
- The
Statement
used to produce this result set. - Throws:
- SQLException - If an error occurs.
getRef
public abstract Ref getRef(int i)
throws SQLException
- This method returns a
Ref
for the specified column which
represents the structured type for the column.
- Parameters:
index
- The index of the column to return.- Returns:
- A
Ref
object for the column - Throws:
- SQLException - If an error occurs.
getBlob
public abstract Blob getBlob(int i)
throws SQLException
- This method returns the specified column value as a BLOB.
- Parameters:
index
- The index of the column value to return.- Returns:
- The value of the column as a BLOB.
- Throws:
- SQLException - If an error occurs.
getRef
public abstract Ref getRef(String colName)
throws SQLException
- This method returns a
Ref
for the specified column which
represents the structured type for the column.
- Parameters:
index
- The index of the column to return.- Returns:
- A
Ref
object for the column - Throws:
- SQLException - If an error occurs.
getBlob
public abstract Blob getBlob(String colName)
throws SQLException
- This method returns the specified column value as a BLOB.
- Parameters:
name
- The name of the column value to return.- Returns:
- The value of the column as a BLOB.
- Throws:
- SQLException - If an error occurs.
updateRef
public abstract void updateRef(int columnIndex,
Ref x)
throws SQLException
- NOTE: removed from SW
- Since:
- 1.4
updateRef
public abstract void updateRef(String columnName,
Ref x)
throws SQLException
- NOTE: removed from SW
- Since:
- 1.4
updateBlob
public abstract void updateBlob(int columnIndex,
Blob x)
throws SQLException
- Since:
- 1.4
updateBlob
public abstract void updateBlob(String columnName,
Blob x)
throws SQLException
- Since:
- 1.4