Firebird: Add ExecuteNonQuery with Transaction
This commit is contained in:
parent
c47209c18c
commit
81b9fa7f63
@ -225,11 +225,20 @@ Public Class Firebird
|
|||||||
''' <param name="SqlCommand">The command to execute</param>
|
''' <param name="SqlCommand">The command to execute</param>
|
||||||
''' <returns>True, if command was executed sucessfully. Otherwise false.</returns>
|
''' <returns>True, if command was executed sucessfully. Otherwise false.</returns>
|
||||||
Public Function ExecuteNonQuery(SqlCommand As String) As Boolean
|
Public Function ExecuteNonQuery(SqlCommand As String) As Boolean
|
||||||
Dim oConnection As FbConnection = GetConnection()
|
Using oConnection As FbConnection = GetConnection()
|
||||||
Dim oScalarValue As Object = ExecuteNonQueryWithConnection(SqlCommand, oConnection)
|
Return ExecuteNonQueryWithConnection(SqlCommand, oConnection)
|
||||||
oConnection.Close()
|
End Using
|
||||||
|
End Function
|
||||||
|
|
||||||
Return oScalarValue
|
''' <summary>
|
||||||
|
''' Executes a non-query command inside the specified transaction.
|
||||||
|
''' </summary>
|
||||||
|
''' <param name="SqlCommand">The command to execute</param>
|
||||||
|
''' <returns>True, if command was executed sucessfully. Otherwise false.</returns>
|
||||||
|
Public Function ExecuteNonQuery(SqlCommand As String, Transaction As FbTransaction) As Boolean
|
||||||
|
Using oConnection As FbConnection = GetConnection()
|
||||||
|
Return ExecuteNonQueryWithConnection(SqlCommand, oConnection, TransactionMode.ExternalTransaction, Transaction)
|
||||||
|
End Using
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
''' <summary>
|
''' <summary>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user