共用方式為


IResultSet.Previous Method

Definition

Moves the cursor to the previous row in this ResultSet object.

[Android.Runtime.Register("previous", "()Z", "GetPreviousHandler:Java.Sql.IResultSetInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null")]
public bool Previous ();
[<Android.Runtime.Register("previous", "()Z", "GetPreviousHandler:Java.Sql.IResultSetInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null")>]
abstract member Previous : unit -> bool

Returns

true if the cursor is now positioned on a valid row; false if the cursor is positioned before the first row

Attributes

Exceptions

if a database error happens.

Remarks

Moves the cursor to the previous row in this ResultSet object.

When a call to the previous method returns false, the cursor is positioned before the first row. Any invocation of a ResultSet method which requires a current row will result in a SQLException being thrown.

If an input stream is open for the current row, a call to the method previous will implicitly close it. A ResultSet object's warning change is cleared when a new row is read.

Added in 1.2.

Java documentation for java.sql.ResultSet.previous().

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to