Java.Sql.IStatement.Execute Method
Executes a supplied SQL statement.

Syntax

[Android.Runtime.Register("execute", "(Ljava/lang/String;I)Z", "GetExecute_Ljava_lang_String_IHandler:Java.Sql.IStatementInvoker, Mono.Android, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null")]
public bool Execute (string sql, int autoGeneratedKeys)

Parameters

sql
the SQL statement to execute.
autoGeneratedKeys
a flag indicating whether to make auto generated keys available for retrieval. This parameter must be one of Statement.NO_GENERATED_KEYS or Statement.RETURN_GENERATED_KEYS.

Returns

Documentation for this section has not yet been entered.

Exceptions

TypeReason
Java.Sql.SQLExceptionif an error occurs accessing the database.

Remarks

Executes a supplied SQL statement. This may return multiple ResultSets. This method allows control of whether auto-generated Keys should be made available for retrieval, if the SQL statement is an INSERT statement.

Use the getResultSet or getUpdateCount methods to get the first result and getMoreResults to get any subsequent results.

[Android Documentation]

Requirements

Namespace: Java.Sql
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0
Since: Added in API level 1