It contains a set of records and iterates particular row of data using cursor. Initially,cursor points to before the first row.
By default, ResultSet object can be moved forward only and it is not updatable. We can change data iteration using cursor types.
Data iteration on this object, will set move forward and backward direction by passing either TYPE_SCROLL_INSENSITIVE or TYPE_SCROLL_SENSITIVE in createStatement(int,int) method as well as we can make this object as updatable by:
public boolean next() | It is used to move the cursor to the one row next from the current position. |
public boolean previous() | it moves the cursor to the one row previous from the current position. |
public boolean first() | It moves the cursor to the first row in result set object. |
public boolean last() | It moves the cursor to the last row in result set object. |
public boolean absolute(int row) | It moves the cursor to the specified row number in the ResultSet object. |
public boolean relative(int row) | It moves the cursor to the relative row number in the ResultSet object, it may be positive or negative. |
public int getInt(int columnIndex) | It returns the data of specified column index of the current row as int. |
public int getInt(String columnName) | It returns the data of specified column name of the current row as int. |
public String getString(int columnIndex) | It returns the data of specified column index of the current row as String. |
public String getString(String columnName) | It returns the data of specified column name of the current row as String. |
0 comments :
Post a Comment