EnumStepLogRecords Method

DTS Programming

DTS Programming

EnumStepLogRecords Method

The EnumStepLogRecords method returns a StepLogRecords collection containing data from the step log records in the database that satisfy the criteria of the input parameters.

Applies To
PackageSQLServer Object
Syntax

Set collection = object.EnumStepLogRecords(
    LineageFullID,
    StepExecutionID
)

Part Description
collection Expression that evaluates to a StepLogRecords collection.
object Expression that evaluates to a PackageSQLServer object.
LineageFullID A globally unique identifier (GUID) string specifying the lineage full ID to which the collection is to be limited.
StepExecutionID A variant specifying the step execution ID to which the collection is to be limited.

Remarks

A step log record is written to the Microsoft® SQL Server™ msdb database on the server specified by the package LogServerName property each time a step in a Data Transformation Services (DTS) package is executed, if the package LogToSQLServer property has been set. For SQL Server 2000 Meta Data Services packages, the log record's lineage full ID links to the package lineage record. For other packages, a GUID is created.

Both parameters are required. To prevent a parameter from participating in the filter process, code the empty string "" for LineageFullID, and NULL for StepExecutionID. Coding all parameters this way will cause all step log records in the database to be returned, which may result in an unmanageably large collection.

The syntax of GUIDs is:

{XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX}

where the X's are hexadecimal digits. The groupings are 8, 4, 4, 4, and 12 digits. The curly brackets are required. Spaces cannot be embedded for readability.

Prototype (C/C++)

HRESULT EnumStepLogRecords(
    BSTR LineageFullID,
    VARIANT StepExecutionID,
    IDTSStepLogRecords **pRetVal );

See Also

LineageFullID Property

LogServerName Property

LogToSQLServer Property

PackageLineages Collection

RemoveStepLogRecords Method

Retrieving DTS System, Package, and Log Data

StepExecutionID Property

StepLogRecords Collection