다음을 통해 공유


GetDataReader 메서드 (String, SqlCommand)

코드에서 직접 이 멤버를 참조하면 안 됩니다. 이 방법은 SQL Server 인프라를 지원합니다. Gets a data reader to execute the specified Transact-SQL statements, and specifying a SqlCommand object that can be used to terminate a long-running query.

네임스페이스:  Microsoft.SqlServer.Management.Sdk.Sfc
어셈블리:  Microsoft.SqlServer.Management.Sdk.Sfc(Microsoft.SqlServer.Management.Sdk.Sfc.dll)

구문

‘선언
Public Function GetDataReader ( _
    query As String, _
    <OutAttribute> ByRef command As SqlCommand _
) As SqlDataReader
‘사용 방법
Dim instance As ExecuteSql
Dim query As String
Dim command As SqlCommand
Dim returnValue As SqlDataReader

returnValue = instance.GetDataReader(query, _
    command)
public SqlDataReader GetDataReader(
    string query,
    out SqlCommand command
)
public:
SqlDataReader^ GetDataReader(
    String^ query, 
    [OutAttribute] SqlCommand^% command
)
member GetDataReader : 
        query:string * 
        command:SqlCommand byref -> SqlDataReader 
public function GetDataReader(
    query : String, 
    command : SqlCommand
) : SqlDataReader

매개 변수

반환 값

유형: System.Data.SqlClient. . :: . .SqlDataReader
A SqlDataReader object that can be used to process the result sets returned by the Transact-SQL statements.