SQLiteDatabase.RawQuery Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
RawQuery(String, String[]) |
Runs the provided SQL and returns a |
RawQuery(String, String[], CancellationSignal) |
Runs the provided SQL and returns a |
RawQuery(String, String[])
Runs the provided SQL and returns a Cursor
over the result set.
[Android.Runtime.Register("rawQuery", "(Ljava/lang/String;[Ljava/lang/String;)Landroid/database/Cursor;", "GetRawQuery_Ljava_lang_String_arrayLjava_lang_String_Handler")]
public virtual Android.Database.ICursor? RawQuery (string? sql, string[]? selectionArgs);
[<Android.Runtime.Register("rawQuery", "(Ljava/lang/String;[Ljava/lang/String;)Landroid/database/Cursor;", "GetRawQuery_Ljava_lang_String_arrayLjava_lang_String_Handler")>]
abstract member RawQuery : string * string[] -> Android.Database.ICursor
override this.RawQuery : string * string[] -> Android.Database.ICursor
Parameters
- sql
- String
the SQL query. The SQL string must not be ; terminated
- selectionArgs
- String[]
You may include ?s in where clause in the query, which will be replaced by the values from selectionArgs. The values will be bound as Strings.
Returns
A Cursor
object, which is positioned before the first entry. Note that
Cursor
s are not synchronized, see the documentation for more details.
- Attributes
Remarks
Runs the provided SQL and returns a Cursor
over the result set.
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
RawQuery(String, String[], CancellationSignal)
Runs the provided SQL and returns a Cursor
over the result set.
[Android.Runtime.Register("rawQuery", "(Ljava/lang/String;[Ljava/lang/String;Landroid/os/CancellationSignal;)Landroid/database/Cursor;", "GetRawQuery_Ljava_lang_String_arrayLjava_lang_String_Landroid_os_CancellationSignal_Handler")]
public virtual Android.Database.ICursor? RawQuery (string? sql, string[]? selectionArgs, Android.OS.CancellationSignal? cancellationSignal);
[<Android.Runtime.Register("rawQuery", "(Ljava/lang/String;[Ljava/lang/String;Landroid/os/CancellationSignal;)Landroid/database/Cursor;", "GetRawQuery_Ljava_lang_String_arrayLjava_lang_String_Landroid_os_CancellationSignal_Handler")>]
abstract member RawQuery : string * string[] * Android.OS.CancellationSignal -> Android.Database.ICursor
override this.RawQuery : string * string[] * Android.OS.CancellationSignal -> Android.Database.ICursor
Parameters
- sql
- String
the SQL query. The SQL string must not be ; terminated
- selectionArgs
- String[]
You may include ?s in where clause in the query, which will be replaced by the values from selectionArgs. The values will be bound as Strings.
- cancellationSignal
- CancellationSignal
A signal to cancel the operation in progress, or null if none.
If the operation is canceled, then OperationCanceledException
will be thrown
when the query is executed.
Returns
A Cursor
object, which is positioned before the first entry. Note that
Cursor
s are not synchronized, see the documentation for more details.
- Attributes
Remarks
Runs the provided SQL and returns a Cursor
over the result set.
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.