Partager via


SQLiteQueryBuilder.Delete(SQLiteDatabase, String, String[]) Method

Definition

Perform a delete by combining all current settings and the information passed into this method.

[Android.Runtime.Register("delete", "(Landroid/database/sqlite/SQLiteDatabase;Ljava/lang/String;[Ljava/lang/String;)I", "GetDelete_Landroid_database_sqlite_SQLiteDatabase_Ljava_lang_String_arrayLjava_lang_String_Handler", ApiSince=29)]
public virtual int Delete (Android.Database.Sqlite.SQLiteDatabase db, string? selection, string[]? selectionArgs);
[<Android.Runtime.Register("delete", "(Landroid/database/sqlite/SQLiteDatabase;Ljava/lang/String;[Ljava/lang/String;)I", "GetDelete_Landroid_database_sqlite_SQLiteDatabase_Ljava_lang_String_arrayLjava_lang_String_Handler", ApiSince=29)>]
abstract member Delete : Android.Database.Sqlite.SQLiteDatabase * string * string[] -> int
override this.Delete : Android.Database.Sqlite.SQLiteDatabase * string * string[] -> int

Parameters

db
SQLiteDatabase

the database to delete on

selection
String

A filter declaring which rows to return, formatted as an SQL WHERE clause (excluding the WHERE itself). Passing null will return all rows for the given URL.

selectionArgs
String[]

You may include ?s in selection, which will be replaced by the values from selectionArgs, in order that they appear in the selection. The values will be bound as Strings.

Returns

the number of rows deleted

Attributes

Remarks

Perform a delete by combining all current settings and the information passed into this method.

Java documentation for android.database.sqlite.SQLiteQueryBuilder.delete(android.database.sqlite.SQLiteDatabase, java.lang.String, java.lang.String[]).

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