Share via


TeamFoundationSqlResourceComponent.AddStatement Method (String, Int32)

Add a statement to the current SQL batch. You must call [PrepareSqlBatch] before you call [AddStatement]. If the number of parameters that will be added by using this statement will exceed the maximum number of allowed parameters in a single SQL batch, the statements that are already part of the batch will be executed, and then a new batch will begin with the statement that's being added.

Namespace:  Microsoft.TeamFoundation.Framework.Server
Assembly:  Microsoft.TeamFoundation.Framework.Server (in Microsoft.TeamFoundation.Framework.Server.dll)

Syntax

'Declaration
Protected Function AddStatement ( _
    sqlStatement As String, _
    parameterCount As Integer _
) As Integer
protected int AddStatement(
    string sqlStatement,
    int parameterCount
)
protected:
int AddStatement(
    String^ sqlStatement, 
    int parameterCount
)
member AddStatement : 
        sqlStatement:string * 
        parameterCount:int -> int
protected function AddStatement(
    sqlStatement : String, 
    parameterCount : int
) : int

Parameters

  • sqlStatement
    Type: System.String

    SQL statement to add to the batch.

  • parameterCount
    Type: System.Int32

    The number of parameters that will be bound after this statement.

Return Value

Type: System.Int32

.NET Framework Security

See Also

Reference

TeamFoundationSqlResourceComponent Class

AddStatement Overload

Microsoft.TeamFoundation.Framework.Server Namespace