Share via


Job.EnumJobStepLogs 메서드 (String)

Enumerates a list of job step log files for the job step with the specified name.

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

구문

‘선언
Public Function EnumJobStepLogs ( _
    stepName As String _
) As DataTable
‘사용 방법
Dim instance As Job 
Dim stepName As String 
Dim returnValue As DataTable 

returnValue = instance.EnumJobStepLogs(stepName)
public DataTable EnumJobStepLogs(
    string stepName
)
public:
DataTable^ EnumJobStepLogs(
    String^ stepName
)
member EnumJobStepLogs : 
        stepName:string -> DataTable
public function EnumJobStepLogs(
    stepName : String
) : DataTable

매개 변수

반환 값

유형: System.Data.DataTable
A DataTable object value that contains an enumerated list of all the job step log files for the job step with the specified name.

The following code example creates a job then displays the job step log files for the specified job step name.

C#

Server srv = new Server("(local)");
Job jb = srv.JobServer.Jobs["Test Job"];
DataTable stepLogs = jb.EnumStepLogs("Test Job Step 1");

PowerShell

$srv = new-object Microsoft.SqlServer.Management.Smo.Server("(local)")
$jb = $srv.JobServer.Jobs["Test Job"]
$stepLogs = $jb.EnumStepLogs("Test Job Step 1")

참고 항목

참조

Job 클래스

EnumJobStepLogs 오버로드

Microsoft.SqlServer.Management.Smo.Agent 네임스페이스

관련 자료

SQL Server 에이전트에서 자동 관리 태스크 예약

관리 태스크 자동화(SQL Server 에이전트)

sp_help_jobsteplog(Transact-SQL)